开发者

App from Xcode works great, but App Store version freezes on load

Has anyone ever heard of this? I'm baffled, and so is Google.

When debugging on iPhone 4 with iOS 4.1, my app shows the splash screen, then shows an animation while it loads and gets the GPS location, and finally goes to the main menu. When I download it from the App Store, it never stops loading. More strange than that, if I hide the forever-loading-app and then restore it, the load animation freezes and the app no longer responds!

I've been trying to make all kinds of guesses about what's going wrong, but nothing is working. How can I get useful information about this failure?

EDIT: App has also been tested on iPhone 3 with iOS 4.0 and iOS 4.2.1, and iPhone 4 with iOS 4.0.2 and 4.2.1.

EDIT EDIT: The problem does not occur if I do not download it from the app store. This makes it extremely difficult to debug, but hopefully narrows it down for somebody out there with more experience th开发者_StackOverflow中文版an I have.


First, it sounds like you've tested your app on one device. Apps should be tested on few devices at least, so you can debug and understand inside flows on several cases.

But if you can't get another device, try elimination. means - try to put unnecessary code under remark, and load only the necessary code. step-by-step you can understand the bug.

It sounds to me like server issue (are you sending any request to a server?), or maybe the gps can't stop searching..?


I agree with Taxman.

First, make sure you tested on different devices with different iOS.

Second, make sure if your app has to connect to servers, those servers are responding in the way you expected.

Third, based on my experience, make sure you tested you app using the Ad Hoc .mobileprovision file other than the Development .mobileprovision file. Xcode will treat binaries differently when compiling.


It seems that the origin of the problem is a bug in iOS 4.1: https://devforums.apple.com/community/iphone/integration/location

Unable to Obtain Location Information on iOS 4.1

Michael Jurewitz at Oct 5, 2010 1:51 PM

There is a known issue in iOS 4.1 where calls to Core Location may not succeed if the app has been removed from a device and reinstalled. Location Services in Settings may also incorrectly show that the app has access to location information. This issue is addressed in iOS 4.2 beta 2.

To work around this issue, select Reset Location Warnings under Settings > General > Reset.

As always, ensure your Core Location delegate properly handles any errors returned from -locationManager:didFailWithError: and -locationManager:monitoringDidFailForRegion:withError:.

Testing based on the above information confirms that resetting location warnings resolves the issue, allowing future runs to progress beyond the loading screen. Reinstalling the app from the app store then causes the issue to occur again. This can be tested repeatedly and cyclicly with consistent results.

To those who responded with suggestions, thank you very much for your time and effort!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜