NSOpenPanel -> system freeze (10.14, Xcode 10)

After installing 10.14 Beta, my system "freezes"* after creating an NSOpenPanel with (at exactly this line):


let panel = NSOpenPanel()


* "freezing" means: I could still move the mouse cursor, but could not push anything. I have to shut down my MacMini late 2012.


Could anybody reproduce this problem?! Or any ideas to solve this problem?


(When launching the same code with XCode 10 on another mac (Mac Book Pro) with 10.13 High Sierra the problem doesn't exist and NSOpenPanel still works ...).

Accepted Reply

Issue fixed with XCode 10 Beta 2/ MacOS 10.14 Beta 2.

Replies

You should submit a bug report, of course, but there is a chance this is not about NSOpenPanel itself. There's always been a pitfall, if the dialog is shown in a view style that shows file previews (e.g. columns view) that it's the preview that freezes up, not the dialog itself. It's worth taking a couple of minutes to make it start at a different file, and see if that makes the problem go away.

How much RAM in your macMini ? Have you check you have not a memory problem ?

I haven't got any experience with bug reports, but I will look for it.


The problem is, that I cannot change any properties of NSOpenPanel. My system freezes the moment I create the object.


I will wait for the second beta of 10.14. If the problem still exists, I will try to reinstall MacOS 10.14 beta.


So you have no problems with NSOpenPanel? I just create a button > let panel = NSOpenPanel > freeze (NSSavePanel the same)

8 GByte ... I think that should be enough for creating one NSOpenPanel ;-)


I even created an empty app with just one button with the line mentioned above and the system freezes.


So you have installed 10.14 and have no problems with creating a NSOpenPanel?

I'm having the same problem.

Thanks for your response.


Posted a bugreport with the number "41196818".

Issue fixed with XCode 10 Beta 2/ MacOS 10.14 Beta 2.

Hello,


I still freezed in same situation.


NSOpenPanel *panel = [NSOpenPanel openPanel];


I'm using Xcode 10 GM and macOS Mojave 10.14 beta 11. iMac Retina 5K 2017 32GB.

najar

The very same problem here since few years. Beachball on object initiation on some machines on Mojave. Contacted Apple Developer Technical Support (DTS) and they believe it's a bug. Also report it to the relevant engineering team, but no response.

Code Block swift
self.dialog = NSOpenPanel();


However if you install xCode and try to debug the project on the same machine that is having this issue it disappears immediately. So the only clue of the issue is the app crash report (attached to this post). If somebody from the Apple side is following this thread please assist.