macOS - Unreal Engine 4.13 - 4.16 hangs every few clicks

So … by removing the corefoundation call

			for (FCocoaWindow* Window : WindowsToClose)
			{
                // issue close to CoreFoudation
				//[Window close];
                
                // clear memory
                [Window release];
			}

it seems to not happen… it feels wrong though … :frowning: cause then any delegates assigned wont get a callback from CF

This is a call that happens quite frequently, and happens outside of most other events.

By commenting out the disposing of the windows it hasnt had a problem :slight_smile: But then again, its not properly telling anything tied to the window that it is closing, so I’m looking at that now, and tonight. We’re getting there…

After an exhaustive day looking at everything inside the box for macOSX/CoreFoundation support, and a bunch of different fixes, the simplest seems to be the top (one I’ll send a PR in for).

Because closing windows is already deferred, there seems to be a race condition between two threads when a window is closed. To counter this we simply say when its time to run the close call it isn’t put off any longer (already is deferred a cycle).

Engine/Source/Runtime/Core/Private/Mac/MacApplication.cpp:1678 ( 4.18 code base )

https://github.com/EpicGames/UnrealEngine/pull/3778

Yes it is 4.16.2 and it still hangs after a few clicks. Epic Games had it for a moment with 4.12 but after that it was downhill from there. Personally I’m very disappointed with Unreal Engine on Mac, so much that I actually considered for a moment switching to Unity. I even considered sending Epic Games my laptop as is. The situation is that bad.

Some workarounds that might or might not work include:

  • Running only Unreal Engine 4.
  • Running it on your main monitor only (without a second one connected, I know this sucks).
  • Letting Unreal load and not do anything for a minute or so.
  • Don’t connect /use USB drives while using Unreal Engine 4.

I don’t know, at this stage they might have something to do with UE crashing all the time or not or maybe it’s a placebo effect. You want my advice? Buy a PC, I’m about to. Too bad though because If we ever want to release anything on a Mac or even iOS, we’re doomed and there doesn’t seem to be a fix on the way anytime soon.

Btw everything else runs flawlessly on my Mac.

If an admin is reading this thread please return it to an UNSOLVED status.

The thing is that the Editor behaves irrational. It can hag every few clicks for hours and suddenly work without problem for hours, with the same apps open in the background. Somewhere the Editor makes a bad call and it hangs.

The Editor has various issues with its windows. Either they flicker when you move them between screens/monitors, lose the pointer tracking, minimize but leave a ghost window lingering.

Nicely done, let’s hope this is the source of the problem.