react-native app fail to start after a few days - ios

I'm gonna try to explain the problem as clearly as possible, here are the steps:
I compile the app on the device (width bundled file on disk - Options 2)
The app starts, and work
After a few days, when i click on the app's icon, it open the 'powered by react-native' screen, then it crash
I had the same problem over multiple devices, and multiple times
I'm pretty sure it is not a JS error, since nothings change between the day it work, and the day it doesnt
here's the app logs on app start:
$ cat crachReport|grep MyApp
Aug 29 14:26:47 Abels-iPhone amfid[1524] <Notice>: /private/var/containers/Bundle/Application/BDC567B0-B341-4B9A-8329-90B5CEC26440/MyApp.app/MyApp not valid: 0xe8008015: A valid provisioning profile for this executable was not found.
Aug 29 14:26:47 Abels-iPhone SpringBoard(BaseBoard)[1682] <Error>: Unable to get pid for 'UIKitApplication:org.reactjs.native.example.MyApp[0x9347]': No such process (err 3)
Aug 29 14:26:47 Abels-iPhone SpringBoard(FrontBoard)[1682] <Error>: Bootstrapping failed for <FBApplicationProcess: 0x1705f9500; org.reactjs.native.example.MyApp; pid: -1>
Aug 29 14:26:47 Abels-iPhone sharingd[62] <Notice>: SystemUI unknown identifier: 'org.reactjs.native.example.MyApp'
the unfound provisionning profile error does not appear on the logs when the app work, so i think it may come from here.
However i'm not sure since i'm new to ios developpement,
Thanks in advance

After compilation with a valid provisionning profile, this problem does not appear.
The default provisionning profile was valid for 7 days, so the error was coming from there.

Related

What does the installation errror "The packet is unknown" mean?

I am trying to use Xcode 6.2 to install a development build of an iOS app onto my iPod touch (running iOS 8.2).
The installation keeps failing with the message
App instalation failed
The packet is unknown.
The console reports the following details:
Mar 27 12:53:52 iPod-touch com.apple.StreamingUnzipService[164] <Warning>: -[StreamingUnzipState finishStream]:476: Finishing an incomplete stream! This stream will not be resumable.
Mar 27 12:53:52 iPod-touch streaming_zip_conduit[163] <Warning>: __dispatch_source_read_socket_block_invoke_2:171: Failed to finish extraction: Error Domain=SZExtractorErrorDomain Code=3 "Finishing an incomplete stream! This stream will not be resumable." UserInfo=0x17e33b50 {SZExtractorFunctionNameErrorKey=-[StreamingUnzipState finishStream], SZExtractorSourceFileLineErrorKey=476, NSLocalizedDescription=Finishing an incomplete stream! This stream will not be resumable.}
Mar 27 12:53:52 iPod-touch streaming_zip_conduit[163] <Warning>: secure_send_message:105: Got error 1 from lockdown_send_message
Mar 27 12:53:52 iPod-touch streaming_zip_conduit[163] <Warning>: secure_send_error:137: Could not send error response to host
These messages seem to imply that the IPA file is somehow corrupted, and can't be extracted, but I had no problem unziping the IPA with Archive Utility on my Mac.
I also already ran codesign -dvvv on Payload/<my-app-name>.app and don't see any obvious problems with the certificate used to sign the app.
What does this error message indicate, and how can the issue be resolved?
note:
I already found this similar question but the only current answer does not help me. Since I have some, possibly relevant, details that may not apply to the previous question, I am asking a new question.
So I was getting this exact error and I tried switching USB ports (from the device plugged into the USB port on my keyboard to the USB port on my laptop) and now it works.

Testflight Ad-hoc distribution does not work if the GoogleMaps.bundle is added to the apps resources

I started to develop an iOS application that needs to use the Google Maps SDK. I followed the steps on the Google web page and added it successfully to the project. The problem is that now my testers cannot download the app via TestFlight, which is distributed with Ad-hoc provision profile and signing. There is an error at the last stage of the progress bar "Unable to download the application right now". -> Done, Retry. I do not know the exact message as it is not English for me. But the message is such small, and the meaning is correct.
The app runs well on the ios simulator, and also on my iphone device, with the working map display as well.
I went through the process now 4 times and finally I was able to identify which step causes this: the step to add the googleMaps.bundle to my resources inside the app. So if I remove the bundle from the list of Frameworks (keep the SDK itself) then the app is compilable, downloadable via TestFlight. If I put it back, it is not. Of course I have runtime crash if the bundle is missing, so I cannot do that.
When i open the console log in the Organizer it tell this:
Nov 26 09:42:17 -iPhone-keszuleke installd[1030] <Error>: 0x2ffe6000 MobileInstallationInstall_Server: Installing app hu.vivify.muzeumtura
Nov 26 09:42:18 -iPhone-keszuleke installd[1030] <Error>: Nov 26 09:42:18 SecTrustEvaluate [leaf CriticalExtensions IssuerCommonName]
Nov 26 09:42:18 -iPhone-keszuleke installd[1030] <Error>: 0x2ffe6000 verify_signer_identity: MISValidateSignatureAndCopyInfo failed for /var/tmp/install_staging.sFC3ox/foo_extracted/Payload/muzeumtura.app/muzeumtura: 0xe8008017
Nov 26 09:42:18 -iPhone-keszuleke installd[1030] <Error>: 0x2ffe6000 do_preflight_verification: Could not verify executable at /var/tmp/install_staging.sFC3ox/foo_extracted/Payload/muzeumtura.app
Nov 26 09:42:18 -iPhone-keszuleke itunesstored[72] <Error>: 0x1698000 MobileInstallationInstall: failed with -1
Nov 26 09:42:18 -iPhone-keszuleke installd[1030] <Error>: 0x2ffe6000 install_application: Could not preflight application install
Nov 26 09:42:18 -iPhone-keszuleke installd[1030] <Error>: 0x2ffe6000 handle_install: API failed
Then after a few more hours I have found the advice of trying the terminal for the codesign command. This gives a lot of missing resources in the googleMaps.bundle:
Desktop/Payload/muzeumtura.app: a sealed resource is missing or invalid
In architecture: armv7
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/._polyline_colors_texture.png
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/nl.lproj/._GMSCore.strings
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/._tr.lproj
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/de.lproj/._GMSCore.strings
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/el.lproj/._GMSCore.strings
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/._ru.lproj
resource missing: /Users/daz/Desktop/Payload/muzeumtura.app/GoogleMaps.bundle/GMSCoreResources.bundle/._ms.lproj
... and so on. It is strange that these files listed are all hidden (starting with ._) I do not know it this has any connection to the Testflight problem, or whether this issue in the terminal is critical or not (this is the first time to use the codesign command for me). But I guess so. Please help me find this out, as it must be something trivial, because the app is very simple and I am sure I am not the only one on this planet who wants to integrate the googleMaps SDK into the ios app.
Some more info:
I have XCode 5.0, OSX 10.8.4
I have enabled to show hidden files in Finder
I want to build for armv7
This is the issue with testflight, sometimes happened with me too. This is not particularly related with google maps, try other methods
Distribute ipa to client
OK, that was my fault. When the GoogleMaps.bundle was added to the project by the drag-n-drop, the bundle was on a disk with exFAT partition table! Who would have thought that this can be a reason? I am sad because one and half day of my life and the project had gone. But I am happy that now it works. Good advice: do not use exFAT for iPhone development!

iOS Ad-Hoc Install fails with proper provisions made

I have done this a dozen times successfully and cannot figure out what is wrong for this instance. I created the deployment certificate, added my devices, and then created my ad-hoc profile using the deployment cert and all devices.
I have a website that allows the user to install the profile and app. The app starts to install and gets to where it is almost done and then it just sits there. It fails for all devices with different flavors of iOS on them.
Any ideas what could be wrong? This is the console output where (altered) line 3 is bugging me. I think this is the primary failure point and I am investigating further. It works fine from my desktop.
Aug 5 09:08:29 MFI-Test-iPad-Mini installd[62] <Notice>: 0x3cf000 MobileInstallationInstall_Server: Installing app com.marketforce.Auditor
Aug 5 09:08:36 MFI-Test-iPad-Mini profiled[213] <Notice>: (Note ) profiled: Service stopping.
Aug 5 09:08:37 MFI-Test-iPad-Mini securityd[78] <Notice>: http asynchttp_timer_proc Timeout during GET http://ocsp.apple.com/ocsp-wwdr01/ThisHasBeenChangedInTheInterestOfSecurity%2BThisHasAlsoBeenAlteredForSecuritym67h1P0%3D.
Aug 5 09:08:37 MFI-Test-iPad-Mini installd[62] <Error>: entitlement 'keychain-access-groups' has value not permitted by provisioning profile 'Adhoc Distribution'
Aug 5 09:08:37 MFI-Test-iPad-Mini installd[62] <Error>: 0x3cf000 verify_signer_identity: MISValidateSignatureAndCopyInfo failed for /var/tmp/install_staging.nkJObR/foo_extracted/Payload/Auditor.app/Auditor: 0xe8008016
Aug 5 09:08:37 MFI-Test-iPad-Mini installd[62] <Error>: 0x3cf000 do_preflight_verification: Could not verify executable at /var/tmp/install_staging.nkJObR/foo_extracted/Payload/Auditor.app
Aug 5 09:08:37 MFI-Test-iPad-Mini installd[62] <Error>: 0x3cf000 install_application: Could not preflight application install
Aug 5 09:08:37 MFI-Test-iPad-Mini itunesstored[89] <Error>: 0x1c3e000 MobileInstallationInstallForLaunchServices: failed with -1
Aug 5 09:08:37 MFI-Test-iPad-Mini itunesstored[89] <Warning>: ERROR: MobileInstallationInstallForLaunchServices returned nil
Aug 5 09:08:37 MFI-Test-iPad-Mini lsd[166] <Warning>: LaunchServices: installation failed for app com.marketforce.Auditor
Aug 5 09:08:37 MFI-Test-iPad-Mini itunesstored[89] <Warning>: LaunchServices: installPhaseFinishedForProgress: com.marketforce.Auditor.Installing - <NSProgress: phase=Installing; state=Failed;
When I hit ad-hoc distribution errors, I have a couple troubleshooting steps to try to narrow it down.
Can you install just the provisioning profile? You should have either a developer or a distribution profile (depending, often times I install both to be sure).
Can you install the app via the iPhone Configuration Utility?
Answering those two questions will point you in the right direction at least. Good luck!
The app was originally created under a developer's appleID and the published in the Business To Business site. The developer left the company and the company created an appleID to be used for the company's development purposes. (Which is what should have been done to begin with).
The app was then transferred to the company's ID however the transfer didn't work right as it left the AppID under the old developer account so any attempt to use certificates and profiles against either account was doomed to failure while using the original AppID. To do any sort of internal deployment, a different AppID had to be created.
After Apple finally got the app transfer fully complete, all was good and the original AppID could once again be used.

Ad-hoc distribution fail

I work for a big company, and I'm developing an iOS app for iOS 5+. The only way the app will be distributed will be through ad-hoc deployment.
I have had my own server for some time, hosted by o2switch (french hoster). As I started the development, we used it to deploy the app for beta testing purposes. It was working pretty well.
As the app entered its final phase, the company bought the same (in fact, they only have a single one) plan at o2switch (as it was working fine on my server). The "new" server works fine, we have the files required by the iOS app on it and we access them correctly.
My problem is that when I deploy over to the company's server, the install keeps crashing ! The bar below the app's icon is empty, the almost full (in no time), and I get an error saying the app could not be installed. (classic)
I have the so-well-known crash log :
unknown itunesstored[1657] <Notice>: MS:Notice: Installing: com.apple.itunesstored [itunesstored] (690.10)
unknown wifid[23] <Error>: WiFi:[375199765.346102]: Client itunesstored is background application
unknown securityd[1659] <Notice>: MS:Notice: Installing: (null) [securityd] (690.10)
unknown SpringBoard[62] <Warning>: could not save thumbnail for downloading icon: image=(null) path='/var/mobile/Library/SpringBoard/DownloadingIconImageCache/***********'
unknown sandboxd[1661] <Notice>: MS:Notice: Installing: (null) [sandboxd] (690.10)
unknown installd[1663] <Notice>: MS:Notice: Installing: (null) [installd] (690.10)
unknown SpringBoard[62] <Warning>: could not save thumbnail for downloading icon: image=(null) path='/var/mobile/Library/SpringBoard/DownloadingIconImageCache/***********'
unknown keybagd[1665] <Notice>: MS:Notice: Installing: (null) [keybagd] (690.10)
unknown securityd[1667] <Notice>: MS:Notice: Installing: (null) [securityd] (690.10)
unknown SpringBoard[62] <Warning>: Killing *********** for app installation
unknown installd[1663] <Error>: 2ffc1000 extract_package: Could not extract archive
unknown installd[1663] <Error>: 2ffc1000 stage_package: Could not extract /var/tmp/install_staging.I0rwBH/foo.zip to /var/tmp/install_staging.I0rwBH/foo_extracted
unknown com.apple.itunesstored[1657] <Notice>: MobileInstallationInstall: failed with -1
unknown installd[1663] <Error>: 2ffc1000 MobileInstallationInstall: Could not stage the package
unknown installd[1663] <Error>: 2ffc1000 handle_install: API failed
unknown installd[1663] <Error>: 2ffc1000 send_message: failed to send mach message of 71 bytes: 10000003
unknown installd[1663] <Error>: 2ffc1000 send_error: Could not send error response to client
I've tried a lot to get rid of this error, but nothing seemed to work. I've read every single answer on SO talking about this issue, and tried everything I could. I re-downloaded the profiles, updated the build number, checked the ipa's url, and so many other things.. Nothing worked.
I had to deliver the app quickly, so I tried one last thing : put it on my server. And it worked perfectly. First try, and with no problem (maybe one, the bar did not load progressively but stayed grey then filled in blue very quick, but that's not a problem, I know it downloaded the online version). Then I re-tried uploading to the new server, same problem.
BTW, I tested with: iPhone4/iOS5, iPhone4S/iOS6, iPhone5/iOS6, iPad3/iOS6 and a couple other devices, over 3G (3 different providers) and Wifi, same problem every single time.
So, my question is the following :
Does / how can the server impact the ad-hoc deployment ?
I can give information on the server's config if required. Please tell me what info you need.
O2switch is investigating, but they don't know much about iOS ad-hoc deployment, so they don't really know where to look, what service the install calls, etc.
So I'm turning (once again) to you, SO's community ! Any ideas ?
Check the mime-type configuration in the web-server. You need:
application/xml for the .plist file, and
application/octet-stream for the .ipa file.
Did you edit the App.plist file before you moved it to the new server?
The assets url must be absolute, like this: <string>http://someurl.com/App-1.0.0.ipa</string>.
If you are absolutely sure that server returns proper mime types, checked by:
lynx -mime_header http://www.serveraddress/App.plist | head -10
If you are sure that you don't have spaces or new lines in link to your .plist file in your html file.
If you are sure that you have added devices to provisioning profile
And if you have read: http://www.informit.com/articles/article.aspx?p=1829415&seqNum=16
I have all files: .plist, .html, .ipa in the same folder
Then I don't know what is the issue and would suggest you to distribute it from your working server.

App crashing immediately after start

EDIT: My problem was because the plist file was corrupted . So if you have the same issue, probably is because of something in you plist file.
SO i have this app and everything worked just fine until i updated my device to IOS 6. After that i couldn't install the app on the device . The app worked just fine on IOS 5.0 simulator and IOS 6.0 simulator . When i try to build it for device , the splash screen appears for two second and then the app closes . In Xcode i receive this error :
timed out waiting for app to launch
I searched the web and it said that it is a AdHoc provisioning problem but my provisioning profiles are in order . I even changed the app id and deleted the old provisioning and i got the same error .
In the device console i receive this weird error :
Oct 15 23:48:23 iPad2-3G backboardd[51] <Warning>: Launch Services: Registered unknown app identifier InvoiceAppDev
��Oct 15 23:48:23 iPad2-3G backboardd[51] <Warning>: Launch Services: Unable to find app identifier InvoiceAppDev
Oct 15 23:48:23 iPad2-3G backboardd[51] <Warning>: Can't create application "InvoiceAppDev" without a bundle path
Oct 15 23:48:44 iPad2-3G mobile_house_arrest[200] <Error>: Max open files: 78
��Oct 15 23:48:44 iPad2-3G installd[30] <Error>: 0x2ff81000 handle_install: Install of "/var/mobile/Media/PublicStaging/InvoiceApp.app" requested by mobile_installation_proxy
Oct 15 23:48:44 iPad2-3G installd[30] <Error>: 0x2ff81000 MobileInstallationInstall_Server: Installing app InvoiceAppDev
��Oct 15 23:48:44 iPad2-3G installd[30] <Error>: Oct 15 23:48:44 SecTrustEvaluate [leaf CriticalExtensions IssuerCommonName]
Oct 15 23:48:45 iPad2-3G installd[30] <Error>: entitlement 'application-identifier' has value not permitted by a provisioning profile
��Oct 15 23:48:45 iPad2-3G installd[30] <Error>: entitlement 'com.apple.developer.ubiquity-container-identifiers' has value not permitted by a provisioning profile
I don't have any clue what happened . Does anybody has any idea why this happened ?
I saw the same error caused by the accidental entry of the following blank field in app.plist:
+ <key>LSApplicationCategoryType</key>
+ <string></string>
I had the exact same symptoms. Believe it or not, I changed my target code signing from distribution to developer and everything worked as expected.
Thanks #nycynik - that solved the problem.
In xcode open the the "Organizer", choose the device (ex. iPhone), select "Application" and delete the previous Version of the
App. Than run again.

Resources