1

I have converted app coded in Swift 2.1 to Swift 4.1, and almost all build related issue solved and now when I am going to run it its giving me error as below.

*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Unable to instantiate the UIApplication subclass instance. No class named Application is loaded.'

*** First throw call stack:
(
    0   CoreFoundation                      0x000000010ff471e6 __exceptionPreprocess + 294
    1   libobjc.A.dylib                     0x000000010f5dc031 objc_exception_throw + 48
    2   CoreFoundation                      0x000000010ff4c472 +[NSException raise:format:arguments:] + 98
    3   Foundation                          0x000000010a75464f -[NSAssertionHandler handleFailureInFunction:file:lineNumber:description:] + 165
    4   UIKit                               0x000000010aca0306 _UIApplicationMainPreparations + 629
    5   UIKit                               0x000000010aca0027 UIApplicationMain + 111
    6   DeÃÅplacement PeÃÅninsule           0x0000000108486271 main + 401
    7   libdyld.dylib                       0x0000000114618955 start + 1
    8   ???                                 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException

Actually I have already check, that its using correct Info.plist.

rmaddy
  • 314,917
  • 42
  • 532
  • 579

3 Answers3

1

The error is saying that it can't find any object of the principal class to instantiate when starting the app. The Principal class entry in the Info.plist file tells the UIApplicationMain() function which class to load on startup. You can try changing that entry to UIApplication, or creating a subclass of UIApplication named Application to fix this.

user1118321
  • 25,567
  • 4
  • 55
  • 86
  • Thanks, actually I just removed NSPrincipalClass entry from list, as I check if I create new project in Xcode 9 with swift 4, there is no such entry, so I removed and now its working. Your answer leads me to check that. Thanks again. – Ankit Patel Jun 19 '18 at 06:48
-1

Symbolication of crash report

1)Copy symbolicatecrash from /Applications/Xcode.app/Contents/ SharedFrameworks/DTDeviceKitBase.framework/Versions/A/Resources/ symbolicatecrash to new folder "crashreport"

2)Goto "crashreoprt" folder

3)Symbolicate using command

Note:

1)Build should be release.

2)Strip debug symbols during copy should be "NO"

3)crashreport folder must have (Symbolicationcrash,.crash and .app)

Prabhat Pankaj
  • 192
  • 1
  • 6
-2

Symbolication of crash report 1)Copy symbolicatecrash from /Applications/Xcode.app/Contents/ SharedFrameworks/DTDeviceKitBase.framework/Versions/A/Resources/ symbolicatecrash to new folder "crashreport" 2)Goto "crashreoprt" folder 3)Symbolicate using command Note: 1)Build should be release. 2)Strip debug symbols during copy should be "NO" 3)crashreport folder must have (Symbolicationcrash,.crash and .app)

Prabhat Pankaj
  • 192
  • 1
  • 6