x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Editor crash when hot-reloading code with Niagara enabled

Hello there,

I've just upgraded to 4.21 and decided to try Niagara. Created an emitter, a system and attached a NiagaraComponent to my character. Everything looks cool, but now every time when I try to recompile my project (with c++ through VS or Editor) Unreal Editor crashes... Here is the stack trace:

 Assertion failed: IsInGameThread() [File:D:\Build\++UE4\Sync\Engine\Plugins\FX\Niagara\Source\Niagara\Private\NiagaraCommon.cpp] [Line: 276]
 
 UE4Editor_Core!FDebug::AssertFailed() [d:\build\++ue4\sync\engine\source\runtime\core\private\misc\assertionmacros.cpp:417]
 UE4Editor_Niagara!FNiagaraScriptDataInterfaceCompileInfo::CanExecuteOnTarget() [d:\build\++ue4\sync\engine\plugins\fx\niagara\source\niagara\private\niagaracommon.cpp:277]
 UE4Editor_Niagara!UNiagaraScript::CanBeRunOnGpu() [d:\build\++ue4\sync\engine\plugins\fx\niagara\source\niagara\private\niagarascript.cpp:1310]
 UE4Editor_Niagara!UNiagaraScript::Serialize() [d:\build\++ue4\sync\engine\plugins\fx\niagara\source\niagara\private\niagarascript.cpp:335]
 UE4Editor_HotReload!FAsyncTask<`FHotReloadModule::ReplaceReferencesToReconstructedCDOs'::`2'::FFindRefTask>::DoWork() [d:\build\++ue4\sync\engine\source\runtime\core\public\async\asyncwork.h:263]
 UE4Editor_HotReload!FAsyncTask<`FHotReloadModule::ReplaceReferencesToReconstructedCDOs'::`2'::FFindRefTask>::DoThreadedWork() [d:\build\++ue4\sync\engine\source\runtime\core\public\async\asyncwork.h:288]
 UE4Editor_Core!FQueuedThread::Run() [d:\build\++ue4\sync\engine\source\runtime\core\private\hal\threadingbase.cpp:455]
 UE4Editor_Core!FRunnableThreadWin::Run() [d:\build\++ue4\sync\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:76]

Maybe I've missed something... Can someone help me, please? P.S. With 4.20 there is the same issue.

Product Version: UE 4.20
Tags:
more ▼

asked Nov 19 '18 at 02:11 PM in Using UE4

avatar image

blink7
60 1 3 8

avatar image Cédric Schaff Jan 14 '19 at 02:39 PM

I have the same error when activating GPU system in the emitter. Once the asset is loaded the error will occur at the next hot reloading. Close it or delete it doesn't prevent the error, you have to close the project and restart it without opening the asset to be able to hot reload.

Disabling GPU doesn't suppress the error. The asset seems to keep some state that trigger the error.

Emitters with CPU work for me.

This prevent me to use niagara, very annoying !

(comments are locked)
10|2000 characters needed characters left

4 answers: sort voted first

Still occurring in 4.21 ... In my case, I've been able to confirm that it is caused by a Particle System asset. I can use my version control to switch between a previous and current revision of a Particle System and with the previous revision, I can hot reload OK. I am still trying to figure out what's different in the new one to see if I can reproduce this reliably with any Particle System. Further, I can remove all emitters from the system so it is completely empty and does nothing, and it still crashes the hot reload. Feels like a form of uasset corruption.

more ▼

answered Dec 21 '18 at 05:34 AM

avatar image

Homer Johnston
6 2

(comments are locked)
10|2000 characters needed characters left

I've had this since 4.20 as well. In addition it causes an error when cooking content:

 UATHelper: Cooking (Windows):   LogWindows: Error: begin: stack for UAT
 UATHelper: Cooking (Windows):   LogWindows: Error: === Critical error: ===
 UATHelper: Cooking (Windows):   LogWindows: Error:
 UATHelper: Cooking (Windows):   LogWindows: Error: Fatal error: [File:C:\Unreal Engine\UnrealEngine\Engine\Source\Runtime\CoreUObject\Private\UObject\UObjectGlobals.cpp] [Line: 305]
 UATHelper: Cooking (Windows):   LogWindows: Error: Illegal call to StaticFindObject() while serializing object data!
 UATHelper: Cooking (Windows):   LogWindows: Error:
 UATHelper: Cooking (Windows):   LogWindows: Error:
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd5b0aa388 KERNELBASE.dll!UnknownFunction []
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd2e3770ca UE4Editor-Core.dll!FWindowsErrorOutputDevice::Serialize() [c:\unreal engine\unrealengine\engine\source\runtime\core\private\windows\windowserroroutputdevice.cpp:63]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd2e15a4e7 UE4Editor-Core.dll!FOutputDevice::LogfImpl() [c:\unreal engine\unrealengine\engine\source\runtime\core\private\misc\outputdevice.cpp:71]
 PackagingResults: Error: begin: stack for UAT
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd2e093147 UE4Editor-Core.dll!FDebug::AssertFailed() [c:\unreal engine\unrealengine\engine\source\runtime\core\private\misc\assertionmacros.cpp:417]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd2ec9cf81 UE4Editor-CoreUObject.dll!StaticFindObject() [c:\unreal engine\unrealengine\engine\source\runtime\coreuobject\private\uobject\uobjectglobals.cpp:308]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf3ef20 UE4Editor-NiagaraShader.dll!FNiagaraDataInterfaceParamRef::InitDIClass() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashader.cpp:1338]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf2ed11 UE4Editor-NiagaraShader.dll!operator<<() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashader.cpp:1369]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf2ec10 UE4Editor-NiagaraShader.dll!operator<<() [c:\unreal engine\unrealengine\engine\source\runtime\core\public\containers\array.h:1100]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf50179 UE4Editor-NiagaraShader.dll!FNiagaraShader::Serialize() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashader.cpp:1284]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd33233d67 UE4Editor-ShaderCore.dll!FShader::SerializeBase() [c:\unreal engine\unrealengine\engine\source\runtime\shadercore\private\shader.cpp:1015]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf50e25 UE4Editor-NiagaraShader.dll!TShaderMap<FNiagaraShaderType>::SerializeInline() [c:\unreal engine\unrealengine\engine\source\runtime\shadercore\public\shader.h:1892]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf503f4 UE4Editor-NiagaraShader.dll!FNiagaraShaderMap::Serialize() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashader.cpp:1103]
 PackagingResults: Error: === Critical error: ===
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf3f8b0 UE4Editor-NiagaraShader.dll!FNiagaraShaderMap::LoadFromDerivedDataCache() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashader.cpp:466]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf364c6 UE4Editor-NiagaraShader.dll!FNiagaraShaderScript::CacheShaders() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashared.cpp:275]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcfbf36c94 UE4Editor-NiagaraShader.dll!FNiagaraShaderScript::CacheShaders() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagarashader\private\niagarashared.cpp:257]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcf4e13710 UE4Editor-Niagara.dll!UNiagaraScript::CacheShadersForResources() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagara\private\niagarascript.cpp:993]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcf4e1333d UE4Editor-Niagara.dll!UNiagaraScript::CacheResourceShadersForCooking() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagara\private\niagarascript.cpp:975]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffcf4e10ed3 UE4Editor-Niagara.dll!UNiagaraScript::BeginCacheForCookedPlatformData() [c:\unreal engine\unrealengine\engine\plugins\fx\niagara\source\niagara\private\niagarascript.cpp:943]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd2ec1558f UE4Editor-CoreUObject.dll!UPackage::Save() [c:\unreal engine\unrealengine\engine\source\runtime\coreuobject\private\uobject\savepackage.cpp:3848]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08f20387 UE4Editor-UnrealEd.dll!UEditorEngine::Save() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\editorengine.cpp:4441]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08dc2b3b UE4Editor-UnrealEd.dll!UCookOnTheFlyServer::SaveCookedPackage() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\cookontheflyserver.cpp:3988]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08dc5361 UE4Editor-UnrealEd.dll!UCookOnTheFlyServer::SaveCookedPackages() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\cookontheflyserver.cpp:2896]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08dd0612 UE4Editor-UnrealEd.dll!UCookOnTheFlyServer::TickCookOnTheSide() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\cookontheflyserver.cpp:2372]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08c33e1b UE4Editor-UnrealEd.dll!UCookCommandlet::CookByTheBook() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\commandlets\cookcommandlet.cpp:882]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd08c65edf UE4Editor-UnrealEd.dll!UCookCommandlet::Main() [c:\unreal engine\unrealengine\engine\source\editor\unrealed\private\commandlets\cookcommandlet.cpp:586]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ff73bbedf15 UE4Editor-Cmd.exe!FEngineLoop::PreInit() [c:\unreal engine\unrealengine\engine\source\runtime\launch\private\launchengineloop.cpp:2478]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ff73bbe4ae2 UE4Editor-Cmd.exe!GuardedMain() [c:\unreal engine\unrealengine\engine\source\runtime\launch\private\launch.cpp:135]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ff73bbe4d2a UE4Editor-Cmd.exe!GuardedMainWrapper() [c:\unreal engine\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:145]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ff73bbf3aaa UE4Editor-Cmd.exe!WinMain() [c:\unreal engine\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:276]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ff73bbf4a16 UE4Editor-Cmd.exe!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:288]
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd5d453034 KERNEL32.DLL!UnknownFunction []
 UATHelper: Cooking (Windows):   LogWindows: Error: [Callstack] 0x00007ffd5e081471 ntdll.dll!UnknownFunction []
 UATHelper: Cooking (Windows):   LogWindows: Error:
 UATHelper: Cooking (Windows):   LogWindows: Error: end: stack for UAT
more ▼

answered Dec 03 '18 at 02:27 PM

avatar image

disseminate
1 1 2

(comments are locked)
10|2000 characters needed characters left

Disabling async level streaming solved this issue for me:

alt text

more ▼

answered Jan 10 '19 at 02:36 AM

avatar image

Wheeze
31 5 5 12

avatar image disseminate Jan 10 '19 at 05:46 PM

I have async loading off and still have the issue

avatar image ShannonGreenwood Feb 21 '19 at 06:05 PM

The async loading thing didn't help me either. Still happening in 4.21.2! Why isn't there more uproar about this? It's murdering iteration times. Is there a bug for this registered somewhere? Are people not using niagara? Or big dev houses have a local fix? Is there a workaround other than pulling the engine from git and using an older version? ( though we're excited about new niagara updates )

avatar image disseminate Feb 21 '19 at 06:12 PM

I've been dealing with it for months now. I really shouldn't have jumped on the niagara ship so fast

avatar image blink7 Feb 21 '19 at 06:51 PM

There is a similar bug, and it seems Epic Games are not interested in development on C++, only Blueprints.

(comments are locked)
10|2000 characters needed characters left

I have the same issue and I didn't manage to reproduc it in a blank project... Did someone have any clue why ? I already try to cleanup all my project folders (.sln, intermediate, binaries, ...) without success.

(I need a way to reproduce it if I want to report the issue ...)


Edit : I managed to found the reproducing steps thanks to @ShannonGreenwood using "GPUSim" in the emitter and send it to Unreal Support. I'm now waiting for their answers and/or the creation of the issue.


Update : I received an answer from the Unreal support :

"While I was able to reproduce your crash with your project, I have also confirmed that this issue no longer occurs in future versions of the engine. Please stay tuned for future updates."

more ▼

answered Mar 08 '19 at 03:58 PM

avatar image

LaZeKler
21 1 4

avatar image blink7 Mar 08 '19 at 06:13 PM

Did you try to create not just a blank project, but from any C++ template and make some changes in the code?

avatar image LaZeKler Mar 08 '19 at 08:35 PM

Unfortunatly yes! I even tried to copy all my C++ classes, used same plugins and copied settings files (.ini) in the fresh blank C++ project. I'm still trying but no success, I can't figure it out! First time i'm hopping the engine crash...

avatar image ShannonGreenwood Mar 12 '19 at 03:23 PM

submitted a bug before I figured out how to reproduce - I don't know how to find that bug now? Should I be able to search for it? Should I have gotten an email about it?

To repro: have gpu sim enabled on a niagara emitter and c++ hotloading will crash

Yesterday - I tried migrating all of my niagara systems into an empty project - maybe the offending niagara emitters weren't loaded and the crash didn't happen. When I changed one of the emitter to gpu sim today, I started getting the crash.

avatar image LaZeKler Mar 13 '19 at 12:39 PM

You're right! I just changed the emitter to "GPU sim" and use the "Full rebuild" then "Compile" and it crashed. I was able to send the reproducing steps to unreal thanks to you!

avatar image ShannonGreenwood Mar 13 '19 at 06:56 PM

I've commented out the checks and things no longer crash. We're going to try this workaround and see if it causes any issues.

 bool FNiagaraScriptDataInterfaceCompileInfo::CanExecuteOnTarget(ENiagaraSimTarget SimTarget) const
 {
     //hack hack, this is causing issues when hotloading - hopefully epic fixes it soon
     //check(IsInGameThread());
     UNiagaraDataInterface* Obj = GetDefaultDataInterface();
     if (Obj)
     {
         return Obj->CanExecuteOnTarget(SimTarget);
     }
     check(false);
     return false;
 }
 
 UNiagaraDataInterface* FNiagaraScriptDataInterfaceCompileInfo::GetDefaultDataInterface() const
 {
     //hack hack, this is causing issues when hotloading - hopefully epic fixes it soon
     //check(IsInGameThread());
     UNiagaraDataInterface* Obj = CastChecked<UNiagaraDataInterface>(const_cast<UClass*>(Type.GetClass())->GetDefaultObject(true));
     return Obj;
 }
avatar image LaZeKler Mar 14 '19 at 08:26 AM

It may work, but I'm pretty sure it's here to prevent some Access Violation from this thread to the game thread. But it seems fair to trade an every time crash with an eventual crash.

avatar image D RUN Apr 01 '19 at 12:54 PM

What file are you changing here?

avatar image ShannonGreenwood Apr 01 '19 at 03:40 PM

NiagaraCommon.cpp

avatar image D RUN Apr 01 '19 at 03:49 PM

Sorry. I should have been more specific. I changed the file here C:\Program Files\Epic Games\UE_4.21\Engine\Plugins\FX\Niagara\Source\Niagara\Private But it's not doing anything. The error message still refers to a file. D:\Build\++UE4\Sync\Engine\Plugins\FX\Niagara\Source\Niagara\Private\NiagaraCommon.cpp but I dont have a d drive

avatar image ShannonGreenwood Apr 01 '19 at 04:42 PM

You can't edit your epic installs. You have to download the engine from git. https://docs.unrealengine.com/en-us/GettingStarted/DownloadingUnrealEngine It's a whole process. Given that this issue should be fixed in 4.22 which should be any day now, you might wait for that.

avatar image LaZeKler Mar 14 '19 at 03:04 PM

I received an answer from the Unreal support :

"While I was able to reproduce your crash with your project, I have also confirmed that this issue no longer occurs in future versions of the engine. Please stay tuned for future updates."

avatar image Cédric Schaff Apr 03 '19 at 02:35 PM

Just tested the bug on the 4.22 -> no more crash ! We can use Niagara now \o/

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question