Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.2k views
in Technique[技术] by (71.8m points)

xcode - Can't use HTTP in iOS 8 simulator

I have installed xcode 6, beta 7 on a MacBook Pro. When I try to use the iOS simulator running iOS 8, and try to connect to any site that is not using HTTPS, I get a blank page stating that "Safari cannot open the page because the network connection was lost" in the simulator. Any page that uses HTTPS works fine.

I have tried various solutions for problems like this, but none of them have worked. These various solutions include restarting the Mac, uninstalling xcode 6 and reinstalling it, and all the proposed solutions in these 2 links:

Unable to run app in Simulator : Xcode beta 6 iOS 8

Unable to run app in Simulator : Xcode beta 6 iOS 8

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I just ran across this response from an Apple employee regarding the issue in the Apple forums:

There is a known issue whereby changes in the host's network configuration (changing wireless networks, changing from wireless to wired, etc) will result in the simulated runtime appearing to loose network connectivity for some cases. The workaround is to just reboot the simulated device.

Restarting the simulator did make my issue go away for some amount of time, but it looks like I need to reboot my simulator any time the Mac changes wifi networks or wakes up. Hopefully they'll release a fix soon, it makes testing impossible. https://devforums.apple.com/message/1048174#1048174


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...