UBT crashes in HotReload.ShouldDoHotReloadFromIDE when a process with an empty executable path is running (macOS)

Summary

Unreal Build Tool throws an unhandled ArgumentException when any running process has an empty executable path. On macOS 27.2.1, an Unreal Editor crash can leave a zombie process with no path behind (Z, PPID 1). After that, every IDE build fails until a reboot.

What Type of Bug are you experiencing?

Foundation (C++ Tools, Profiling, & Pipeline)

Steps to Reproduce

On macOS 27.2.1, launch Unreal Editor 5.8.4 for a C++ project.
Crash the editor.
Check for a zombie: ps -axo pid,ppid,stat,comm | awk ‘$3 ~ /Z/’ shows with PPID 1.
Build the project from an IDE (Rider), or run Build.sh without -NoHotReloadFromIDE.
UBT fails with the exception above.

Expected Result

UBT skips processes it can’t resolve to a path and continues the build.

Observed Result

UBT stops with Result: Failed (OtherCompilationError).

Affects Versions

5.8

Platform(s)

Mac

For crash reports, include your callstack

ArgumentException: The value cannot be an empty string. (Parameter ‘path’)
at System.IO.Path.GetFullPath(String path)
at EpicGames.Core.FileReference..ctor(String inPath)
at UnrealBuildTool.HotReload.ShouldDoHotReloadFromIDE(…)
at UnrealBuildTool.HotReload.GetDefaultMode(…)
at UnrealBuildTool.HotReload.Setup(…)
at UnrealBuildTool.BuildMode.BuildAsync(…)

Additional Notes

Workarounds found:
Passing -NoHotReloadFromIDE on the command line works.
Setting bAllowHotReloadFromIDE=false in BuildConfiguration.xml does not avoid the crash.
Adding -NoHotReloadFromIDE to Rider’s optional build parameters has no effect.
A reboot clears the zombie until the next editor crash.

Suggested fix:
In ShouldDoHotReloadFromIDE, skip processes whose filename is null or empty, or catch the exception, before creating the FileReference. It would also help if the BuildConfiguration.xml setting turned this check off.

Related:
The zombie process itself appears to be a macOS 27 crash reporting issue (the ReportCrashService connection is interrupted while handling the crash). I’ve reported it to Apple separately, but UBT should handle the empty path either way.