When the "Is Variable" box is unchecked for a BP-typed child widget, a variable will not be created at Blueprint compile time to reference the child widget in the nativized widget BP class. This breaks dependency analysis during nativization at cook time, as the child widget class will no longer be seen as a load dependency.

Current suggested workaround is to ensure that the "Is Variable" box is checked for any child widget that is of a Blueprint type, if Blueprint nativization is enabled for the cooked build.

Steps to Reproduce
  1. Open the sample project attached to the support thread in UE4 editor.
  2. Choose File->Package Project->Windows->Win64, choose a location and wait for packaging to finish.
  3. Attempt to launch the packaged EXE. Note that an error will result at runtime:
    LogClass: Error: CDO is created for a dynamic class, before the class was constructed. /Game/Hud/BP_ChildWidget.BP_ChildWidget_C

> Example-Win64-Debug.exe!FConvertedBlueprintsDependencies::FillUsedAssetsInDynamicClass(UDynamicClass * DynamicClass, void[Image Removed](TArray<FBlueprintDependencyData,TSizedDefaultAllocator<32> > &) GetUsedAssets) Line 3006 C++
Example-Win64-Debug.exe!UBP_ChildWidget_C_pf197907997::_CustomDynamicClassInitialization(UDynamicClass * InDynamicClass) Line 443 C++
Example-Win64-Debug.exe!UClass::CreateDefaultObject() Line 3142 C++
Example-Win64-Debug.exe!UDynamicClass::CreateDefaultObject() Line 5457 C++
Example-Win64-Debug.exe!UBP_HudWidget_C_pf197907997::_CustomDynamicClassInitialization(UDynamicClass * InDynamicClass) Line 469 C++
Example-Win64-Debug.exe!UClass::CreateDefaultObject() Line 3142 C++
Example-Win64-Debug.exe!UDynamicClass::CreateDefaultObject() Line 5457 C++
Example-Win64-Debug.exe!FAsyncPackage::EventDrivenCreateExport(int LocalExportIndex) Line 2840 C++
Example-Win64-Debug.exe!FAsyncPackage::ProcessImportsAndExports_Event() Line 3477 C++
Example-Win64-Debug.exe!FAsyncPackage::Event_ProcessImportsAndExports() Line 2517 C++
Example-Win64-Debug.exe!FAsyncLoadingThread::QueueEvent_ProcessImportsAndExports::__l2::<lambda>(FAsyncLoadEventArgs & Args) Line 2292 C++
Example-Win64-Debug.exe!UE4Function_Private::TFunctionRefCaller<void <lambda>(FAsyncLoadEventArgs &),void __cdecl(FAsyncLoadEventArgs &)>::Call(void * Obj, FAsyncLoadEventArgs & <Params_0>) Line 549 C++
Example-Win64-Debug.exe!UE4Function_Private::TFunctionRefBase<UE4Function_Private::TFunctionStorage<0>,void __cdecl(FAsyncLoadEventArgs &)>::operator()(FAsyncLoadEventArgs & <Params_0>) Line 677 C++
Example-Win64-Debug.exe!FAsyncLoadEventQueue::PopAndExecute(FAsyncLoadEventArgs & Args) Line 107 C++
Example-Win64-Debug.exe!FAsyncLoadingThread::ProcessAsyncLoading(int & OutPackagesProcessed, bool bUseTimeLimit, bool bUseFullTimeLimit, float TimeLimit, FFlushTree * FlushTree) Line 4041 C++
Example-Win64-Debug.exe!FAsyncLoadingThread::TickAsyncThread(bool bUseTimeLimit, bool bUseFullTimeLimit, float TimeLimit, bool & bDidSomething, FFlushTree * FlushTree) Line 4842 C++
Example-Win64-Debug.exe!FAsyncLoadingThread::TickAsyncLoading(bool bUseTimeLimit, bool bUseFullTimeLimit, float TimeLimit, FFlushTree * FlushTree) Line 4520 C++
Example-Win64-Debug.exe!FAsyncLoadingThread::FlushLoading(int PackageID) Line 6986 C++
Example-Win64-Debug.exe!FlushAsyncLoading(int PackageID) Line 569 C++
Example-Win64-Debug.exe!LoadPackageInternal(UPackage * InOuter, const wchar_t * InLongPackageNameOrFilename, unsigned int LoadFlags, FLinkerLoad * ImportLinker, FArchive * InReaderOverride, FUObjectSerializeContext * InLoadContext) Line 1110 C++
Example-Win64-Debug.exe!LoadPackage(UPackage * InOuter, const wchar_t * InLongPackageName, unsigned int LoadFlags, FArchive * InReaderOverride, FUObjectSerializeContext * InLoadContext) Line 1426 C++
Example-Win64-Debug.exe!UEngine::LoadMap(FWorldContext & WorldContext, FURL URL, UPendingNetGame * Pending, FString & Error) Line 12537 C++
Example-Win64-Debug.exe!UEngine::Browse(FWorldContext & WorldContext, FURL URL, FString & Error) Line 11975 C++
Example-Win64-Debug.exe!UGameInstance::StartGameInstance() Line 530 C++
Example-Win64-Debug.exe!UGameEngine::Start() Line 1135 C++
Example-Win64-Debug.exe!FEngineLoop::Init() Line 3695 C++
Example-Win64-Debug.exe!EngineInit() Line 52 C++
Example-Win64-Debug.exe!GuardedMain(const wchar_t * CmdLine, HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, int nCmdShow) Line 157 C++
Example-Win64-Debug.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow) Line 252 C++

Have Comments or More Details?

There's no existing public thread on this issue, so head over to AnswerHub just mention UE-87624 in the post.

Login to Vote

ComponentGameplay - Blueprint
Affects Versions4.224.234.24
CreatedJan 28, 2020
UpdatedFeb 10, 2021