iOS 8 enterprise apps are stuck in limbo inside the device - ios

In trying to release a new update to one of my enterprise iOS apps, I'm finding that the OTA download is failing. It will give me the "Would you like to install 'xxx'" alert, and tapping 'Install' is about as far as it will go. There's no indication that anything is happening. This occurs on my iPhone 6 and iPad both running the most recent release of iOS 8.
Running the devices on the iPhone Configuration Utility, it shows the list of installed apps, and the one app that is refusing to install has an "Install" button where all the others have "Uninstall." In the screen cap below you'll see the renamed bundle and the original bundle.
When I click the "Install" button, the iPhone Configuration Utility crashes.
I managed to get it to work using a workaround that I found elsewhere on StackOverflow, which requires renaming the app's Bundle Identifier, but it still seems like a pi$$-poor way to do it.
It seems clear that the app is somehow stuck in limbo, showing up on the app list but not showing up on the iPhone screen, and also is refusing to be overwritten. My question is, is there a way to purge the old app from the iPhone's memory, and possibly reload it using the original Bundle Identifier?

Apple still hasn't fixed this correctly in even the latest versions. There are several manifestations: the app does download, but the device doesn't quit the calling app, so you don't know if the app downloads or not. If the app was never on your device before, it usually downloads. If it was there before, and was deleted, it doesn't download. If the downloaded app is already running in the background, or you're doing in-app downloading, it often doesn't download because it doesn't want to replace a running app. I usually start the download, then switch immediately to the springboard to watch it download. If I see the clock dial on the app icon, then I know it's downloading. Changing the bundle is not a good thing, not to mention not giving any user feedback when you tap "Install."

As far as updating the app from the in app prompt.
It's a problem with apple/ios8. They aren't exiting the app after the install. If you quickly tap the home button after you hit install. Occasionally you will get a successful download.
For future use you could find out a way to use exit which will kill the app but apple warns against using exit due to poor user experience. But if apple isn't providing a good user experience in the first place for this process I think this warrants the use imho.

Related

App freezes several seconds before start on device

I'm a free developer and I use my swift application on my iPhone 7. I'm using Swift 3 and iOS 10.
So the problem is, sometimes (like 2 of 10 times) when I start the app, iOS freezes like 5 seconds before my app actualy comes to the screen. In this time I only see the app icon is in the highlighted state. This only happens with my own app, not with other apps.
My app also does nothing special on startup and this only happens on the real device, the debugger in Xcode always starts immediately.
So is this a normal behavior? And does it work properly when I decide to put it on the App Store?
Thanks in advance.
I have had this happen to me before. No, this does not happen when it is put out on the App Store. One way to get around this is to use TestFlight. You can upload your archive to apple and select on the 'TestFlight' tab of your app. Click on internal testing and then click on your email and the version of the app you want to test. You should then get an email on your Apple ID telling you to test the app, and it will let you download it. Good question :)
To test the same version which would have been uploaded to the store quickly, change the build configuration to release. To do so, click on your app's name (top left), press edit schema, click the build configuration dropdown, also deselect debug executable. (make sure to turn it back when you're going to debug, or create a new schema with the above settings to let you switch quickly in the future)
You might also try using instruments, that lag on startup might happen if you're trying to load many things in memory on your initial view controller's viewDidLoad or app delegate's didFinishLaunchingWithOptions load, especially when trying to load big files such as images, videos or large plists. You might want to try using instruments (the time profiler instrument specifically) in order to check it out.

My WatchOS2 app stuck on launch with Spinner

I built a demo app on WatchOS 2.0.1, on every launch it was getting stuck with App name on Top Left corner and spinner in middle of screen on iWatch (38mm). Watch is brand new and have only native apps installed till now so there should not be any issue with memory.
I tried many times to open the app but it was repeatedly closing automatically after showing Spinner for sometime. After lots of trial my Apps screen got visible and then after on every launch it worked fine without sticking on launch. I tried to double check by Force quit my app using Power button but it worked fine then after.
Then I uninstalled the app from watch and reinstalled it and same thing happened again. It started sticking. Do anyone have Idea on this? Please help on this part.
WatchOS Version : 2.0.1
Your app is crashing, as evidenced by it "automatically closing."
You should be able to track down the reason for the crash by examining the crash report (which can be found in the Xcode Window -> Devices pane). Alternately, you should be able to interactively debug this by running the app within Xcode.
As for it eventually no longer crashing until you deleted and reinstalled the app, the app reached a state where the reason for the crash no longer occurred. This probably is related to needing to handle some error pertaining to a path or file which it is finally able to create or access. Deleting the app recreated the condition where it repeatedly crashed again.

How to debug an iOS app that does not make it past launch for certain users?

I have hundreds of people using my app, but a handful are reporting that the app does not make it past the black launch screen (it immediately closes, before entering into my app). I'm using Crittercism but it's not even getting far enough to catch any exception, which makes it sound like a springboard / backboard problem.
Here's what I've asked the users to do:
Reinstall the app
Delete some apps (to free some space)
Restart the device
None of the above worked. I'm completely at a loss as to what's wrong. The app is in the AppStore and works fine for most users. Furthermore, I can't find anything unique about these users (they're using recent versions of iOS with fairly modern hardware).
Crittercism doesn't show anything, because after the crash - log will be send only at the next launch, so if user doesn't open your app anymore (or can't do it, because he has constant crash).
I advice your to try next ideas:
Do use use keychain or store smth there? It's not cleared after uninstall
Maybe your data is backed up in icloud
Did it begin with the new iOs version (9.0 for example)
Maybe it's some cache problem after installing one version on another,
Can it be the problem of different timezones
Can it be a crash with local settings
If you have feedback with users with crash - contact them and ask about device, iOs version and other
your have crash sections in your itunesconnect profile, maybe there you'll get some information

iOS 8.1.3 - Enterprise distribution not working

we have a few apps that we install on our devices using an Enterprise distribution profile. To install an app, we use the usual itms-services link:
itms-services://?action=download-manifest&url=...
We use the same link to install updates to the apps.
Ever since this latest iOS update (8.1.3) something strange is happening with the link. On some devices, and only for one or two of the apps, the link does absolutely nothing. It pops up the dialog with Install or Cancel, but when the user presses Install nothing happens. The app's icon doesn't get the loading overlay, nothing. To make matters worse, all the apps on all the devices have been installed the exact same way, yet it only happens to some apps on some devices. An app that installs fine on one device will have this problem on another.
On one of the devices that are having this problem, I even tried uninstalling the app, and then running the link again, but still nothing happens. In fact, now I can't install the app at all on that device, since nothing happens when the link is clicked!
Things I've tried:
Restarting the device
Removing all profiles from the device
Does anyone know what's going on, and how to fix it?
Ok, so I found a hacky way around this bug. If I change the bundle ID in the manifest file to something different, such as adding "-ios8fix" or something to the end, then it'll install. It doesn't look as nice, since during the installation there's a second app icon on the screen. But once the installation is finished, the second icon disappears.
One benefit of doing it this way though, is that if the installation fails the user can still use the old version of the app, since there'll temporarily be 2 icons, one for the old version, and one for the update...

ios 8 openUrl itms-services does not exit current app

In iOS 6 or 7, the app exit to the home screen when I call UIApplication openUrl with a url of itms-services://XXXX to install a new version of my app (using enterprise deployment with ipa files).
In iOS 8, this is no longer the case. Now the app continue running just as nothing has happened, but if I go the home screen, I can see my app icon grayed out, with a downloading pie chart about 66% completed and the text "Downloading..." below. If I now wait for a while (less than a minute), the application is installed correctly and I can start my app again.
Has anyone else experienced this behavior? Have anyone seen any documentation regarding this? I can accept behavioral changes as long as it is documented, but I haven't seen any documentation regarding this.
While forcing the app to crash will technically work, a much better solution (allowing the user to retain the state of the application) would be to simply background the app launching the itms-services link by executing the following.
[[UIApplication sharedApplication] performSelector:#selector(suspend)];
We use this in an app used for distributing test builds to our testers and it works very well, and eliminates the confusion of a tester trying to install an app and having the app stay in front. It also allows them to return to our distribution app and have it pick up where they were.
Yes, you also get the same behaviour when clicking a download link in safari now on iOS8.
I'm not sure why they introduced this change but there isn't really a way around it (unless you force your app to crash with something like exit(0);)
Also, the itms-services url scheme is undocumented and is technically a private api. From experience, you're not allowed to submit apps to the App Store that use it.
I have experienced a similar thing. I have a web page for our internal app store and when I tap on the link I do get a prompt asking if I want to install and when I say yes safari just sits there. The app is downloading on the home screen but under IOS 7 safari would be pushed to the background and you could see where your app is being downloaded to and its progress. Now it appears like nothing is happening. I would love to correct this. Perhaps something has changed in the .plist files the itms-services protocol uses. This protocol is not private it is just reserved for enterprise deployments.

Resources