Description

Loading all the levels selected in the Content Browser and running the aforementioned Python script causes the editor to crash

 

Tested in 4.20.3 (CL - 4369336), 4.21.2 (CL - 4753647), 4.22 (CL - 5660361), 4.23 (CL - 5915479)

Steps to Reproduce
  1. Create a Blank project
  2. Enable the Python and Scripting Utilities plugins
  3. Save the current level as NewMap
  4. Create several duplicates of the current level
  5. Select all of those levels in the Content Browser
  6. Execute the following Python script:
import unreal

@unreal.uclass()
class MyEditorUtility(unreal.GlobalEditorUtilityBase):
   pass

editor_util = MyEditorUtility()
levels = editor_util.get_selected_assets()

for level in levels:
   level_path_name = level.get_path_name().split(':')[0].split('.')[0]

   unreal.EditorLevelLibrary.load_level(level.get_path_name())
   unreal.EditorLoadingAndSavingUtils.save_map(level.get_world(), level_path_name)

      7. Repeat steps 5 and 6

 

Expected: All of the levels are loaded and saved

Result: The Editor crashes

Callstack

UE4Editor_CoreUObject!UStruct::IsChildOf() [d:\build\++ue4\sync\engine\source\runtime\coreuobject\public\uobject\class.h:381]
UE4Editor_HotReload!FHotReloadModule::ReinstanceClasses() [d:\build\++ue4\sync\engine\source\developer\hotreload\private\hotreload.cpp:1229]
UE4Editor_HotReload!TBaseRawMethodDelegateInstance<0,FHotReloadModule,void __cdecl(void)>::ExecuteIfSafe() [d:\build\++ue4\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:518]
UE4Editor_PythonScriptPlugin!FPyWrapperTypeReinstancer::ProcessPending() [d:\build\++ue4\sync\engine\plugins\experimental\pythonscriptplugin\source\pythonscriptplugin\private\pywrappertyperegistry.cpp:375]
UE4Editor_PythonScriptPlugin!TBaseFunctorDelegateInstance<bool __cdecl(float),<lambda_07fa3f9a91924747b22889f4378e05d4> >::Execute() [d:\build\++ue4\sync\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:893]
UE4Editor_Core!FTicker::Tick() [d:\build\++ue4\sync\engine\source\runtime\core\private\containers\ticker.cpp:95]
UE4Editor!FEngineLoop::Tick() [d:\build\++ue4\sync\engine\source\runtime\launch\private\launchengineloop.cpp:3894]
UE4Editor!GuardedMain() [d:\build\++ue4\sync\engine\source\runtime\launch\private\launch.cpp:174]
UE4Editor!GuardedMainWrapper() [d:\build\++ue4\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:145]
UE4Editor!WinMain() [d:\build\++ue4\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:276]
UE4Editor!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:283]
kernel32
ntdll

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-72853 in the post.

0
Login to Vote

Fixed
ComponentUE - Editor - Workflow Systems
Affects Versions4.224.234.21.2
Target Fix4.22.1
Fix Commit5956901
Main Commit5956925
CreatedApr 16, 2019
ResolvedApr 17, 2019
UpdatedJan 22, 2024
View Jira Issue