Application crashes if we compile in Xcode 9 - swift

Application started crashing on device when we build application from Xcode 9, the application is working fine on the simulator but crashes on the device. Below are the device crash logs
Crash logs
Sep 22 18:57:33 iPhone ReportCrash(CrashReporterSupport)[324] <Notice>:
Process: Checkout [323]
Path:
/private/var/containers/Bundle/Application/13FD366C-4D41-4BC9-B958-
151CDC9E62F3/Checkout.app/Checkout
OS Version: iPhone OS 10.3.3 (14G60)
Sep 22 18:57:33 iPhone ReportCrash(CrashReporterSupport)[324] <Notice>:
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Description: DYLD, Library not loaded:
#rpath/libclang_rt.ubsan_ios_dynamic.dylib | Referenced from:
/private/var/containers/Bundle/Application/13FD366C-4D41-4BC9-B958-
151CDC9E62F3/Checkout.app/Frameworks/Valid.framework/Base | Reason:
image not found
Embed swift library flag is true and application successfully compiled on machine its crashing as soon as we launch app on device.

Related

Xcode 12.4 crashes when opening any project

Xcode keeps crashing whenever I try to run any .xcodeproj or .xcworkspace project.
Solutions I've tried are: reinstalling Xcode, deleting derived data, and deleting xcuserstate folder.
Xcode keeps failing with the below error:
Process: Xcode [7099]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 12.4 (17801)
Build Info: IDEFrameworks-17801000000000000~7 (12D4e)
App Item ID: 497799835
App External ID: 839994694
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [7099]
User ID: 501
Date/Time: 2021-03-13 11:03:31.401 +0100
OS Version: macOS 11.0.1 (20B29)
Report Version: 12
Anonymous UUID: 007E7CE0-17B1-C3EF-5191-4E8908451B4E
Sleep/Wake UUID: 310A38F4-3A1F-4C76-8D12-A255873336E7
Time Awake Since Boot: 28000 seconds
Time Since Wake: 570 seconds
System Integrity Protection: enabled
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
ProductBuildVersion: 12D4e
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEFrameworks/IDEFrameworks-17801/IDEKit/Workspace/IDEWorkspaceDocument.m:3270
Details: (tabController) should not be nil.
Object: <IDEWorkspaceDocument: 0x7fa04eecbff0>
Method: -commitStateToDictionary:
Thread: <NSThread: 0x7fa045904c20>{number = 1, name = main}
Open FDs: 41/7168
Hints:
I have the same problem as you but on my side Xcode crashes only when I open a project directly from the fast project opening window (the one that opens when Xcode is launched)
Try to open the project through the Finder or from the terminal directly with the command open /nameProject/xcWorkspace
I don't have any problems with this method.

XCode 12 Preview Crashes when adding Firebase SDK Swift UI 2.0

Since the last Xcode update to 12.0.1 SwiftUI previews crashes when is added to the project.
The crash log hints that the problem is located in the firebase sdk, more specific the
GoogleDataTransport/GDTCORLibrary
System Integrity Protection: enabled
Crashed Thread: 3 Dispatch queue: com.google.GDTCORFlatFileStorage
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[NSFileManager enumeratorAtURL:includingPropertiesForKeys:options:errorHandler:]: URL is nil'
terminating with uncaught exception of type NSException
Firebase (6.33) is integrated via cocoapods (1.10.0.rc.1) with
Xcode 12.0.1 on Catalina 10.15.7
There is an open issue on github
Someone found a solution or workaround for this?
Downgrading GoogleDataTransport from 7.4.0 to 7.3.0 does the trick however If you use Firebase 6.33.0 downgrading will not work because version GoogleDataTransport 7.4 version was locked in Firebase Core podspec. According to crash report Preview crashes in AppDelegate FirebaseApp.configure(), so if Firebase functionality isn't required in DEBUG it might be excluded with macros:
#if RELEASE
FirebaseApp.configure()
#endif
Downgrading GoogleDataTransport from 7.4.0 to 7.3.0 fixes the problem
=> pod 'GoogleDataTransport', '7.3.0'

Xcode says Build is successful, but app is not installed on iPhone

I'm using Xcode 4.3.2 with the deployment target set to 4.1 and the iOS is 4.2.1 on an iPhone 3Gs. Whenever I build and run the application with the iPhone 3Gs as the target, it says "finished running 'app name' on 'iPhone 3Gs'.
I have a provision profile setup for this iPhone 3Gs
I checked organizer, and the circle to the right of the iPhone name is green
I ran the same app on my iPhone 4s with the deployment target set to 4.1 and it installed and runs on my iPhone 4s.
Any ideas as to what might be going on that is not installing the app on the iPhone 3Gs? I even tried searching for the app using spotlight, and nothing came up.
Thanks!
EDIT:
this is what appears in my device console log:
Fri May 18 15:27:39 unknown lockdownd[16] <Error>: 2ff68000 handle_connection: Could not receive USB message #6 from iTunes. Killing connection
Fri May 18 15:27:39 unknown com.apple.mobile.lockdown[16] <Notice>: Could not receive size of message
Fri May 18 15:27:51 unknown MobileStorageMounter[4978] <Notice>: (0x3e7518b8) platform_supports_camera_import: Platform is NOT configured for camera import
Fri May 18 15:28:01 unknown MobileStorageMounter[4978] <Notice>: (0x3e7518b8) idle_timer_callback: Exiting after idle
Make sure you have armv6 and armv7 for your 'Valid Architectures' in Build settings, because the 3Gs won't work on the defaulted armv7 only

Xcode 4.0.2 Crashes on launch

Xcode crashes on launch, and I do not have any idea why. I downloaded 4.0.2 + iOS SDK (4.3) and installed it. Then I tried to open it and it crashed on launch... Here is my console log that relates to the crash
enter cdyld: Library not loaded: /System/Library/PrivateFrameworks/CoreSymbolication.framework/Versions/A/CoreSymbolication 6/14/11 6:10:55 PM [0x0-0x287287].com.apple.dt.Xcode[18402]
Referenced from: /iPhoneSDK/Applications/Xcode.app/Contents/MacOS/../../../../Library/PrivateFrameworks/DVTFoundation.framework/Versions/A/DVTFoundation 6/14/11 6:10:55 PM [0x0-0x287287].com.apple.dt.Xcode[18402]
Reason: image not found 6/14/11 6:10:55 PM [0x0-0x287287].com.apple.dt.Xcode[18402]
catch_mach_exception_raise_state_identity(): PID: 18405 thread: 0x16c77 type: 0xa code: 0x1000f7044 codeCnt: 0x2 flavor: 0x1000f7054 old_state: 0x1000f705c old_stateCnt: 0x2c new_state: 0x1000f802c new_stateCnt: 0x1000f8028 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]
(com.apple.ReportCrash.Self[18405]) Job appears to have crashed: Trace/BPT trap 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]
catch_mach_exception_raise_state_identity(): PID: 18404 thread: 0x17037 type: 0xa code: 0x7fff5fbfdf14 codeCnt: 0x2 flavor: 0x7fff5fbfdf24 old_state: 0x7fff5fbfdf2c old_stateCnt: 0x2c new_state: 0x7fff5fbfe43c new_stateCnt: 0x7fff5fbfe438 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]
(com.apple.ReportCrash[18404]) Job appears to have crashed: Trace/BPT trap 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]
catch_mach_exception_raise_state_identity(): PID: 18402 thread: 0x1703b type: 0xa code: 0x7fff5fbfdf14 codeCnt: 0x2 flavor: 0x7fff5fbfdf24 old_state: 0x7fff5fbfdf2c old_stateCnt: 0x2c new_state: 0x7fff5fbfe43c new_stateCnt: 0x7fff5fbfe438 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]
([0x0-0x287287].com.apple.dt.Xcode[18402]) Job appears to have crashed: Trace/BPT trap 6/14/11 6:10:55 PM com.apple.launchd.peruser.501[167]ode here
It looks like CoreSymbolication does not exist on your machine. I would uninstall and reinstall.
I had a similar problem with two Xcode versions which both failed to start.
I initially had Xcode 4.0.1 (back then the world was still a good place).
I wanted to see how our App looks when compiled with the current iOS SDK 5.0
So I installed Xcode 4.2 on top of Xcode 4.0.1 (overriding it completely)
I tested some stuff in my app and realized that I need to fallback to Xcode < 4.2
I installed Xcode 4.1. During the installation process the installer told me that the current installation would move from /Developer to /Developer-4.2
After all this neither of installed Xcode versions worked anymore which is bad.
I decided to uninstall Xcode 4.2 first and then reinstall Xcode 4.1 again.
I uninstalled Xcode 4.2 with the command sudo /Developer-4.2/Library/uninstall-devtools
I run the Xcode 4.1 installer again from /Applications/Install Xcode.app
After the installation Xcode 4.1 opened so it worked again...
I reinstalled via sudo /Developer/Library/uninstall-devtools and the App Store
But the offending source was restored, so Xcode crashed again. Boo!
I renamed the offending source's folder so Xcode couldn't find it.
Xcode couldn't find the source, and never crashed, which allowed me to get back to work.
Extremely Obvious Feature Request to Apple: hold 'option' to suppress previous projects from loading, plus a command line to do the same.

Uploading to iTunesConnect with Organiser crashes

I've been trying to re-upload a previously uploaded app (it originally failed submission), but both the 'Validate' and the 'Submit' button in Organiser crash Organiser itself before finishing. This has been happening for about three days now, and I haven't heard a word back from the iTunesConnect helpdesk. I am running the lastest Xcode 3.2.5 with iOS 4.2.1, and downloaded and installed the latest Application Tools as instructed. Everything installed fine.
I'm getting a:
with:
Process: Xcode [32144]
Path: /Developer/Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.Xcode
Version: 3.2.5 (1760)
Build Info: DevToolsIDE-17600000~5
Code Type: X86-64 (Native)
Parent Process: launchd [348]
Date/Time: 2010-12-03 17:29:50.499 +1000
OS Version: Mac OS X 10.6.5 (10H574)
Report Version: 6
Interval Since Last Report: 4332 sec
Crashes Since Last Report: 2
Per-App Interval Since Last Report: 1215 sec
Per-App Crashes Since Last Report: 2
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Crashed Thread: 7 Dispatch queue: com.apple.root.default-priority
Application Specific Information:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[ITunesSoftwareApplicationDescription applicationType]: unrecognized selector sent to instance 0x200c57ae0'
*** Call stack at first throw:
(
0 CoreFoundation 0x00007fff840087b4 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x00007fff886ea0f3 objc_exception_throw + 45
2 CoreFoundation 0x00007fff84062110 +[NSObject(NSObject) doesNotRecognizeSelector:] + 0
3 CoreFoundation 0x00007fff83fda91f ___forwarding___ + 751
I know that this isn't the place to debug Apple apps - but someone must have had this happen and figured out how to get past it? I'm getting no joy from apple :(
thanks
As a work around, you could try Application Loader.app in /Developer/Applications/Utilities.
I generally find this more reliable.
You should create an .ipa file for you App and then use application loader as Andrew said.
Worked for me.
Btw nobody can get joy from a computer company ;) ... Apple or any other...
Check what version of Xcode you're running. I had a similar issue where I was running a developer preview - you can't submit an app from a DP version of Xcode, and mine was crashing at the exact same point as yours.
Hope this helps.