Strange crashes starting from Xcode Version 11.2.1 (11B500)

My app worked fine without any crash but after upgrading to Version 11.2.1 (11B500) many strange things happen, I tried the Version 11.3 beta (11C24b) without any success.


To remove any doubts related to my apps I can reproduce the crash starting a new clean project

  1. create the project for MacOS -> App
  2. language Objective-C and very important check
    Create Document-Based Application
  3. run the application, the window application appears
  4. Open two other windows with the shortcut CMD+N
  5. close the app with CMD+Q
  6. the app crashes (see the stacktrace below)


I've tried with two different macs both with 10.14.6 so I think the problem is related to Xcode itself

Any hint?


2019-11-26 09:05:31.852866+0100 CrashEPoi[1918:173418] Metal API Validation Enabled

2019-11-26 09:05:34.169223+0100 CrashEPoi[1918:173418] *** _NSDocumentBasicAsyncOperation 0x60000024adc0 went isFinished=YES without being started by the queue it is in

2019-11-26 09:05:34.169398+0100 CrashEPoi[1918:173418] *** _NSDocumentBasicAsyncOperation 0x60000024b560 went isFinished=YES without being started by the queue it is in

2019-11-26 09:05:34.170040+0100 CrashEPoi[1918:173759] [General] An uncaught exception was raised

2019-11-26 09:05:34.170145+0100 CrashEPoi[1918:173759] [General] *** -[__NSOperationInternal _start:]: something is trying to start the receiver simultaneously from more than one thread

2019-11-26 09:05:34.170281+0100 CrashEPoi[1918:173759] [General] (

0 CoreFoundation 0x00007fff4d515bc9 __exceptionPreprocess + 256

1 libobjc.A.dylib 0x00007fff77cb93c6 objc_exception_throw + 48

2 CoreFoundation 0x00007fff4d5159fb +[NSException raise:format:] + 193

3 Foundation 0x00007fff4f6f0b19 -[__NSOperationInternal _start:] + 265

4 Foundation 0x00007fff4f71ac77 __NSOQSchedule_f + 227

5 libdispatch.dylib 0x0000000100345e7c _dispatch_call_block_and_release + 12

6 libdispatch.dylib 0x0000000100346f1b _dispatch_client_callout + 8

7 libdispatch.dylib 0x000000010034a2be _dispatch_continuation_pop + 563

8 libdispatch.dylib 0x00000001003493b4 _dispatch_async_redirect_invoke + 769

9 libdispatch.dylib 0x0000000100359824 _dispatch_root_queue_drain + 334

10 libdispatch.dylib 0x000000010035a2da _dispatch_worker_thread2 + 125

11 libsystem_pthread.dylib 0x00000001003c00b7 _pthread_wqthread + 583

12 libsystem_pthread.dylib 0x00000001003bfe01 start_wqthread + 13

)

2019-11-26 09:05:34.176607+0100 CrashEPoi[1918:173759] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSOperationInternal _start:]: something is trying to start the receiver simultaneously from more than one thread'

*** First throw call stack:

(

0 CoreFoundation 0x00007fff4d515bc9 __exceptionPreprocess + 256

1 libobjc.A.dylib 0x00007fff77cb93c6 objc_exception_throw + 48

2 CoreFoundation 0x00007fff4d5159fb +[NSException raise:format:] + 193

3 Foundation 0x00007fff4f6f0b19 -[__NSOperationInternal _start:] + 265

4 Foundation 0x00007fff4f71ac77 __NSOQSchedule_f + 227

5 libdispatch.dylib 0x0000000100345e7c _dispatch_call_block_and_release + 12

6 libdispatch.dylib 0x0000000100346f1b _dispatch_client_callout + 8

7 libdispatch.dylib 0x000000010034a2be _dispatch_continuation_pop + 563

8 libdispatch.dylib 0x00000001003493b4 _dispatch_async_redirect_invoke + 769

9 libdispatch.dylib 0x0000000100359824 _dispatch_root_queue_drain + 334

10 libdispatch.dylib 0x000000010035a2da _dispatch_worker_thread2 + 125

11 libsystem_pthread.dylib 0x00000001003c00b7 _pthread_wqthread + 583

12 libsystem_pthread.dylib 0x00000001003bfe01 start_wqthread + 13

)

libc++abi.dylib: terminating with uncaught exception of type NSException

(lldb)

I tested on 11.2ß2. OSX 10.14.6


Did exactly as described.

No crash on quitting.


Did the same test on another Mac, with OSX 10.14.6, XCode 11.2.1.

No crash either on quit.

Mojave 10.14.6, tested on two different macs

2 to 2 - draw 😉


So, we need to find what is the difference between us


Could it be default parameters set when creating a project ?


If you want to past an email address for a minute, we shall exchange our projects and test..

Thanks for your time,


I've upload the zipped project

Thanks.


I tested, no crash here.


Only difference is that multiple windows show as stacked and not just over each other.


May be you should try reinstalling XCode, or testing with 11.3 beta.

This is really strange


I tried the Version 11.3 beta (11C24b) and crashes in the same manner, it's impossible to find where is the problem, two different machines crashing in the same manner for new projects

Strange crashes starting from Xcode Version 11.2.1 (11B500)
 
 
Q