Description

Adding a code class to a blueprint project causes the editor to crash after attempting to hot reload.

This only occurs for a fully bluprint project, code projects or BP projects that have already had a class added do not crash when additional classes are added

Regression:
Yes - same steps do not crash in 4.17.2 (CL 3658906)

Steps to Reproduce
  1. Open UE4 Editor (blank blueprint project)
  2. Add code to project based on Actor

Result:
Editor crashes after attempting to compile the new class

Expected:
Class is added / editor hot reloads after compiling.

Callstack
LoginId:7156c35640f86204e61b8383f45dee17
EpicAccountId:c807849e05a0413d99e379f2802cae9c

Fatal error: [File:D:\Build\++UE4+Release-4.18+Compile\Sync\Engine\Source\Runtime\CoreUObject\Private\Templates\Casts.cpp] [Line: 10] Cast of nullptr to Package failed

UE4Editor_Core!FDebug::AssertFailed() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\private\misc\assertionmacros.cpp:414]
UE4Editor_CoreUObject!CastLogError() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\private\templates\casts.cpp:11]
UE4Editor_CoreUObject!CastChecked<UPackage,UObject>() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\public\templates\casts.h:211]
UE4Editor_CoreUObject!UE4CodeGen_Private::ConstructUPackage() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\private\uobject\uobjectglobals.cpp:4418]
UE4Editor_MyProject15!Z_Construct_UPackage__Script_MyProject15()
UE4Editor_CoreUObject!UE4CodeGen_Private::ConstructUClass() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\private\uobject\uobjectglobals.cpp:4443]
UE4Editor_MyProject15!Z_Construct_UClass_AMyActor()
UE4Editor_CoreUObject!UObjectLoadAllCompiledInDefaultProperties() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\private\uobject\uobjectbase.cpp:742]
UE4Editor_CoreUObject!ProcessNewlyLoadedUObjects() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\coreuobject\private\uobject\uobjectbase.cpp:839]
UE4Editor_CoreUObject!TBaseStaticDelegateInstance<void __cdecl(void)>::ExecuteIfSafe() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:1027]
UE4Editor_Core!TBaseMulticastDelegate<void>::Broadcast() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegatesignatureimpl.inl:937]
UE4Editor_Core!FModuleManager::LoadModuleWithFailureReason() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\private\modules\modulemanager.cpp:487]
UE4Editor_Core!FModuleManager::LoadModule() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\private\modules\modulemanager.cpp:338]
UE4Editor_Core!FModuleManager::LoadModuleWithCallback() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\private\modules\modulemanager.cpp:1107]
UE4Editor_HotReload!FHotReloadModule::RecompileModule() [d:\build\++ue4+release-4.18+compile\sync\engine\source\developer\hotreload\private\hotreload.cpp:726]
UE4Editor_GameProjectGeneration!GameProjectUtils::AddCodeToProject_Internal() [d:\build\++ue4+release-4.18+compile\sync\engine\source\editor\gameprojectgeneration\private\gameprojectutils.cpp:3664]
UE4Editor_GameProjectGeneration!GameProjectUtils::AddCodeToProject() [d:\build\++ue4+release-4.18+compile\sync\engine\source\editor\gameprojectgeneration\private\gameprojectutils.cpp:1139]
UE4Editor_GameProjectGeneration!SNewClassDialog::FinishClicked() [d:\build\++ue4+release-4.18+compile\sync\engine\source\editor\gameprojectgeneration\private\snewclassdialog.cpp:1181]
UE4Editor_GameProjectGeneration!TBaseSPMethodDelegateInstance<0,SNewClassDialog,0,TTypeWrapper<void> __cdecl(void)>::Execute() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:327]
UE4Editor_GameProjectGeneration!TBaseSPMethodDelegateInstance<0,SNewClassDialog,0,void __cdecl(void)>::ExecuteIfSafe() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:434]
UE4Editor_AppFramework!SWizard::HandleFinishButtonClicked() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\appframework\private\widgets\workflow\swizard.cpp:287]
UE4Editor_AppFramework!TMemberFunctionCaller<SWizard,FReply (__cdecl SWizard::*)(void) __ptr64>::operator()<>() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegateinstanceinterface.h:165]
UE4Editor_AppFramework!UE4Tuple_Private::TTupleImpl<TIntegerSequence<unsigned int> >::ApplyAfter<TMemberFunctionCaller<SWizard,FReply (__cdecl SWizard::*)(void) __ptr64> >() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\templates\tuple.h:497]
UE4Editor_AppFramework!TBaseSPMethodDelegateInstance<0,SWizard,0,FReply __cdecl(void)>::Execute() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:327]
UE4Editor_Slate!TBaseDelegate<FReply>::Execute() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\core\public\delegates\delegatesignatureimpl.inl:537]
UE4Editor_Slate!SButton::OnMouseButtonUp() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\widgets\input\sbutton.cpp:282]
UE4Editor_Slate!<lambda_1002768c627006711ef2f351a87ec0e7>::operator()() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5263]
UE4Editor_Slate!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,<lambda_1002768c627006711ef2f351a87ec0e7> >() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:234]
UE4Editor_Slate!FSlateApplication::RoutePointerUpEvent() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5252]
UE4Editor_Slate!FSlateApplication::ProcessMouseButtonUpEvent() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5750]
UE4Editor_Slate!FSlateApplication::OnMouseUp() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5730]
UE4Editor_ApplicationCore!FWindowsApplication::ProcessDeferredMessage() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:1725]
UE4Editor_ApplicationCore!FWindowsApplication::DeferMessage() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:2171]
UE4Editor_ApplicationCore!FWindowsApplication::ProcessMessage() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:888]
UE4Editor_ApplicationCore!FWindowsApplication::AppWndProc() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\applicationcore\private\windows\windowsapplication.cpp:725]
user32
user32
UE4Editor_ApplicationCore!FWindowsPlatformApplicationMisc::PumpMessages() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\applicationcore\private\windows\windowsplatformapplicationmisc.cpp:129]
UE4Editor!FEngineLoop::Tick() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\launch\private\launchengineloop.cpp:3220]
UE4Editor!GuardedMain() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\launch\private\launch.cpp:166]
UE4Editor!GuardedMainWrapper() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:134]
UE4Editor!WinMain() [d:\build\++ue4+release-4.18+compile\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:210]
UE4Editor!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:253]
kernel32
ntdll

Have Comments or More Details?

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

0
Login to Vote

Fixed
ComponentCore
Affects Versions4.18
Target Fix4.18
Fix Commit3677338
Release Commit3677338
CreatedOct 5, 2017
ResolvedOct 11, 2017
UpdatedApr 27, 2018