{"id":4553,"date":"2017-05-21T18:58:54","date_gmt":"2017-05-21T10:58:54","guid":{"rendered":"https:\/\/unitycoder.com\/blog\/?p=4553"},"modified":"2017-05-21T19:00:30","modified_gmt":"2017-05-21T11:00:30","slug":"ios-app-crashes-only-if-downloaded-from-appstore-or-testflight","status":"publish","type":"post","link":"https:\/\/unitycoder.com\/blog\/2017\/05\/21\/ios-app-crashes-only-if-downloaded-from-appstore-or-testflight\/","title":{"rendered":"iOS App crashes only if downloaded from Appstore or TestFlight"},"content":{"rendered":"<p>Had annoying issue with one ios app, it worked perfectly when build locally from xcode to device,<br \/>\nbut after uploading to AppStore, that version crashes in all devices. Solution was rather simple:<\/p>\n<h3>Solution<\/h3>\n<ul>\n<li>Disable [ ] Include bitcode option when uploading your app archive to itunes connect (because apparently they do some compiling in app store, which can break your project, in my case it seems like they stripped out some required classes from MoonSharp..?)<\/li>\n<\/ul>\n<p><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"4554\" data-permalink=\"https:\/\/unitycoder.com\/blog\/2017\/05\/21\/ios-app-crashes-only-if-downloaded-from-appstore-or-testflight\/xcode-archive-build-settings\/\" data-orig-file=\"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?fit=680%2C339&amp;ssl=1\" data-orig-size=\"680,339\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"xcode-archive-build-settings\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?fit=680%2C339&amp;ssl=1\" class=\"alignnone size-full wp-image-4554\" src=\"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?resize=680%2C339&#038;ssl=1\" alt=\"\" width=\"680\" height=\"339\" srcset=\"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?w=680&amp;ssl=1 680w, https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?resize=300%2C150&amp;ssl=1 300w\" sizes=\"auto, (max-width: 680px) 100vw, 680px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Resources \/ Tips for debugging TestFlight &amp; AppStore apps<\/strong> (since you cannot connect xcode debugger)<\/p>\n<ul>\n<li>Use runtime debug loggers like <a href=\"https:\/\/www.assetstore.unity3d.com\/en\/content\/27688?aid=1101lGti\" target=\"_blank\" rel=\"noopener noreferrer\">SRDebugger <\/a>(paid plugin), or <a href=\"https:\/\/github.com\/bbbscarter\/UberLogger\" target=\"_blank\" rel=\"noopener noreferrer\">UberLogger <\/a>(free), can see the actual error message here!<\/li>\n<li>From <a href=\"https:\/\/docs.unity3d.com\/Manual\/class-PlayerSettingsiOS.html\" target=\"_blank\" rel=\"noopener noreferrer\">Player Settings<\/a> enable: &#8220;Script Call Optimizations: Slow &amp; Safe&#8221; (because Fast &amp; No Exceptions crashes, slow and safe at least wont crash in most cases it seems)<\/li>\n<li>View device logs by connecting your iphone\/ipad to Mac, then in Xcode select Window \/ Devices \/ yourdevice, &#8230; view logs (but il2cpp makes it bit useless, &#8216;crashed at 89829034 + 127837&#8217; ?)<\/li>\n<li>Use TestFlight with <a href=\"https:\/\/developer.apple.com\/library\/content\/documentation\/LanguagesUtilities\/Conceptual\/iTunesConnect_Guide\/Chapters\/SettingUpUserAccounts.html\" target=\"_blank\" rel=\"noopener noreferrer\">iTunesconnect users<\/a>, this means the build is available for testing quite fast after uploading (no need to wait for beta build review for external testers)<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Had annoying issue with one ios app, it worked perfectly when build locally from xcode to device, but after uploading to AppStore, that version crashes in all devices. Solution was rather simple: Solution Disable [ ] Include bitcode option when uploading your app archive to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":4554,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[420,3],"tags":[989,188,988,738,481,994,991,196,987,986,992,993,990,809],"class_list":["post-4553","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials","category-unity3d","tag-appstore","tag-build","tag-crash","tag-debug","tag-error","tag-exception","tag-il2cpp","tag-ios","tag-ipad","tag-iphone","tag-log","tag-logging","tag-published","tag-xcode"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2017\/05\/xcode-archive-build-settings.jpg?fit=680%2C339&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/p1KTaT-1br","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4553","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/comments?post=4553"}],"version-history":[{"count":3,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4553\/revisions"}],"predecessor-version":[{"id":4557,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4553\/revisions\/4557"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/media\/4554"}],"wp:attachment":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/media?parent=4553"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/categories?post=4553"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/tags?post=4553"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}