HangsAreFatal is true on shipping build ?

We are seeming some behaviour on our deployed servers that hangs are causing a crash. We don’t actually set that value to true. Is there something that modifies this behaviour on shipping builds ? Our test builds only report hangs as errors on deployment.

Hi,

As far as I can see, nothing in the engine turns HangsAreFatal to true. The bHangsAreFatal default to false in D:\UE_5.4\Engine\Source\Runtime\Core\Private\HAL\ThreadHeartBeat.cpp:

FThreadHeartBeat::FThreadHeartBeat() : Thread(nullptr) ... , bHangsAreFatal(false) ... { It could be turned true if UE_ASSERT_ON_HANG was defined, but it default to 0 and I could not find a definition elsewhere.

#ifndef UE_ASSERT_ON_HANG #define UE_ASSERT_ON_HANG 0 #endifFinally, it can change in and Engine .ini file, but I didn’t find such definition in the engine code.

GConfig->GetBool(TEXT("Core.System"), TEXT("HangsAreFatal"), bNewHangsAreFatal, GEngineIni);Maybe you have this defined? It would be defined for some console by the engine, but it would not depend on the config (Test vs Shipping)

#define MINIMAL_FATAL_HANG_DETECTION (PLATFORM_USE_MINIMAL_HANG_DETECTION && 1)Otherwise, do you get a callstack/dump, or can you attach the debugger to the process and get exactly why it crashes? Debugging void FThreadHeartBeat::InitSettings() would tell you for sure what’s the value of bHangsAreFatal.

Regards,

Patrick

The crash report client gets loaded right after the log about hang on the game thread. The hang is from some game code waiting for a background asset load to happen. The logs do read as if the crash is due to the hang. The signal 0 and reiteration of the Hang at the end.

I am asking internally to see if we turn it on somehow. But does not seem like it.

The crash happens in a shipped server already deployed. I don’t see it turned on after testing locally.

{"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: Hang detected on GameThread (thread hasn't sent a heartbeat for 10.00 seconds):\n","stream":"stdout","time":"2025-04-30T01:31:08.278617027Z"} . . {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x0000000008863b7e BelfryServer-Linux-Shipping!FEngineLoop::Tick() [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/Launch/Private/LaunchEngineLoop.cpp:5941]\n","stream":"stdout","time":"2025-04-30T01:31:08.279012944Z"} {"log":"sh: 1: xdg-user-dir: not found\n","stream":"stderr","time":"2025-04-30T01:31:08.46915813Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x0000000008864b0a BelfryServer-Linux-Shipping!GuardedMain(char16_t const*) [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/Launch/PrivatLogPakFile: Initializing PakPlatformFile\n","stream":"stdout","time":"2025-04-30T01:31:08.611968952Z"} {"log":"LogPakFile: Display: Found Pak file ../../../Engine/Programs/CrashReportClient/Content/Paks/CrashReportClient.pak attempting to mount.\n","stream":"stdout","time":"2025-04-30T01:31:08.612025755Z"} . . . {"log":"[2025.04.30-01.31.10:629][ 0]LogCore: Engine exit requested (reason: CrashReportClientApp RequestExit)\n","stream":"stdout","time":"2025-04-30T01:31:10.632480247Z"} {"log":"[2025.04.30-01.31.10:629][ 0]LogExit: Preparing to exit.\n","stream":"stdout","time":"2025-04-30T01:31:10.632484747Z"} {"log":"[2025.04.30-01.31.10:630][ 0]LogExit: Object subsystem successfully closed.\n","stream":"stdout","time":"2025-04-30T01:31:10.632489047Z"} {"log":"[2025.04.30-01.31.10:631][ 0]LogPakFile: Destroying PakPlatformFile\n","stream":"stdout","time":"2025-04-30T01:31:10.667607004Z"} {"log":"[2025.04.30-01.31.10:633][ 0]LogExit: Exiting.\n","stream":"stdout","time":"2025-04-30T01:31:10.667691907Z"} {"log":"e/Launch.cpp:182]\n","stream":"stdout","time":"2025-04-30T01:31:10.672756817Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x0000000008857c0b BelfryServer-Linux-Shipping!CommonUnixMain(int, char**, int (*)(char16_t const*), void (*)()) [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/Unix/UnixCommonStartup/Private/UnixCommonStartup.cpp:269]\n","stream":"stdout","time":"2025-04-30T01:31:10.672837521Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x00007f5634238d90 libc.so.6!UnknownFunction(0x29d8f)\n","stream":"stdout","time":"2025-04-30T01:31:10.672879222Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x00007f5634238e40 libc.so.6!__libc_start_main(+0x7f)\n","stream":"stdout","time":"2025-04-30T01:31:10.672883923Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: 0x000000000470a029 BelfryServer-Linux-Shipping!_start()\n","stream":"stdout","time":"2025-04-30T01:31:10.672888223Z"} {"log":"[2025.04.30-01.31.08:278][298]LogCore: Error: Hang detected on GameThread:\n","stream":"stdout","time":"2025-04-30T01:31:10.672892423Z"} {"log":" 0x0000000004957afa BelfryServer-Linux-Shipping!FUnixPlatformStackWalk::CaptureStackBackTrace(unsigned long long*, unsigned int, void*) [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/Core/Private/Unix/UnixPlatformStackWalk.cpp:765]\n","stream":"stdout","time":"2025-04-30T01:31:10.672896723Z"} {"log":" 0x000000000494465c BelfryServer-Linux-Shipping!ThreadStackWalker(int, siginfo_t*, void*) [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/Core/Private/Unix/UnixPlatformCrashContext.cpp:1060]\n","stream":"stdout","time":"2025-04-30T01:31:10.672901423Z"} {"log":" 0x00007f5634251520 libc.so.6!UnknownFunction(0x4251f)\n","stream":"stdout","time":"2025-04-30T01:31:10.672905824Z"} {"log":" 0x0000000004a42d27 BelfryServer-Linux-Shipping!FAsyncLoadingThread2::UpdateSyncLoadContext(FAsyncLoadingThreadState2\u0026, bool) [D:/Stoic/work/9af7f4bc46f4c7b8/Engine/Source/./Runtime/CoreUObject/Private/Serialization/AsyncLoading2.cpp:7638]\n","stream":"stdout","time":"2025-04-30T01:31:10.672910024Z"} {"log":"\n","stream":"stdout","time":"2025-04-30T01:31:10.672915924Z"} {"log":"Check log for full callstack.\n","stream":"stdout","time":"2025-04-30T01:31:10.672920224Z"} {"log":"Engine crash handling finished; re-raising signal 0 for the default handler. Good bye.\n","stream":"stdout","time":"2025-04-30T01:31:10.672924324Z"} {"log":"LogPakFile: Display: Mounting pak file ../../../Engine/Programs/CrashReportClient/Content/Paks/CrashReportClient.pak.\n","stream":"stdout","time":"2025-04-30T01:31:08.612030055Z"} {"log":"LogPakFile: Display: Mounted Pak file '../../../Engine/Programs/CrashReportClient/Content/Paks/CrashReportClient.pak', mount point: '../../../Engine/'\n","stream":"stdout","time":"2025-04-30T01:31:08.612033955Z"} {"log":"LogICUInternationalization: ICU TimeZone Detection - Raw Offset: +0:00, Platform Override: ''\n","stream":"stdout","time":"2025-04-30T01:31:08.612038355Z"}

we caught a live instance of this today. The logs were cutting off and we assumed it was a crash. But looks like the process was just stuck. Thanks for the help.

Good, I’m glad this is sorted out. Let us know if you need something else!