Description

in the past we have reported a lot of VM related bugs which got fixed over time. Unfortunately, I think we have another one.

 

Right now we're using 5.0.3 binaries from the launcher.

 

Now the problem is that whenever we're trying to load the same variant manager file for the second time in a single PIE execution, it crashes in `UPropertyValue::HasValidResolve`.

 

It's access violation and the debugger says the problem is at line 615 (which may be slightly inaccurate given this is Development Editor target). The line says this: `Container->IsUnreachable()`. Looking at the Container pointer, I can see it contains some trash and not a real valid data, so my guess is that it got GCed but the pointer somehow survived that.

In packaged game, there are now problems. It's just PIE and standalone.

Steps to Reproduce

We spawn the actor from C++ using SpawnActor()

We use FActorSpawnParameters to override the level to spawn the variant manager in. The reason is just to tie it's lifetime with that of the level. This is most likely not related, but mentioning it in case it may come in handy.

We hold the isntance in a UPROPERTY attribute, it doesn't get GCed or anything.

It crashes when trying to switch on one particular variant of a one particular set, but right before that it is able to switch several other variants of the same variant sets asset without any problem.

And again, first time the VM asset is created, it works without any problems, but after you destroy it and create a new instance, it's gonna crash for one specific variant.

We had problems like that in the past, but I thought you guys fixed all of them. It was usually fixed by deleting the set and creating it anew. But the difference is that back then it wouldn't work even the first time (which makes more sense).

Callstack
  1. [Inline Frame] UnrealEditor-VariantManagerContent.dll!FUObjectArray::IndexToObject(int Index) Line 718 C++
  2. [Inline Frame] UnrealEditor-VariantManagerContent.dll!UObjectBaseUtility::IsUnreachable() Line 311 C++
  3. UnrealEditor-VariantManagerContent.dll!UPropertyValue::HasValidResolve() Line 615 C++
  4. UnrealEditor-VariantManagerContent.dll!UPropertyValue::Resolve(UObject * Object) Line 539 C++
  5. UnrealEditor-VariantManagerContent.dll!UPropertyValue::ApplyDataToResolvedObject() Line 703 C++
  6. UnrealEditor-VariantManagerContent.dll!UVariant::SwitchOn() Line 273 C++
  7. UnrealEditor-VariantManagerContent.dll!ALevelVariantSetsActor::SwitchOnVariantByName(FString VariantSetName, FString VariantName) Line 66 C++
  8. UnrealEditor-VisualizationPlugin.dll!AVariantManagerVisualization::update(const FString & jsonString) Line 47 C++
  9. UnrealEditor-MARC_2.dll!AConfigurationView::HandleVariantManagerUpdate(const FString & json) Line 784 C++
  10. [Inline Frame] UnrealEditor-MARC_2.dll!AConfigurationView::HandleConfigurationUpdate::__l2::<lambda_636b5eb453d919b0f532819bf4f69884>::operator()(FString) Line 747 C++
  11. [Inline Frame] UnrealEditor-MARC_2.dll!Invoke(AConfigurationView::HandleConfigurationUpdate::__l2::<lambda_636b5eb453d919b0f532819bf4f69884> &) Line 47 C++
  12. [Inline Frame] UnrealEditor-MARC_2.dll!UE::Core::Private::Tuple::TTupleBase<TIntegerSequence<unsigned int>>::ApplyAfter(AConfigurationView::HandleConfigurationUpdate::__l2::<lambda_636b5eb453d919b0f532819bf4f69884> &) Line 324 C++
  13. UnrealEditor-MARC_2.dll!TBaseFunctorDelegateInstance<void __cdecl(FString),FDefaultDelegateUserPolicy,<lambda_636b5eb453d919b0f532819bf4f69884>>::ExecuteIfSafe(FString <Params_0>) Line 836 C++
  14. [External Code]
  15. [Inline Frame] UnrealEditor-CalClientWrapperPlugin.dll!UE::Core::Private::Function::TFunctionRefBase<UE::Core::Private::Function::TFunctionStorage<1>,void __cdecl(void)>::operator()() Line 676 C++
  16. [Inline Frame] UnrealEditor-CalClientWrapperPlugin.dll!TFunctionGraphTaskImpl<void __cdecl(void),0>::DoTaskImpl(TUniqueFunction<void __cdecl(void)> &) Line 1457 C++
  17. [Inline Frame] UnrealEditor-CalClientWrapperPlugin.dll!TFunctionGraphTaskImpl<void __cdecl(void),0>::DoTask(ENamedThreads::Type) Line 1450 C++
  18. UnrealEditor-CalClientWrapperPlugin.dll!TGraphTask<TFunctionGraphTaskImpl<void __cdecl(void),0>>::ExecuteTask(TArray<FBaseGraphTask *,TSizedDefaultAllocator<32>> & NewTasks, ENamedThreads::Type CurrentThread, bool bDeleteOnCompletion) Line 975 C++
  19. [Inline Frame] UnrealEditor-Core.dll!FBaseGraphTask::Execute(TArray<FBaseGraphTask *,TSizedDefaultAllocator<32>> & CurrentThread, ENamedThreads::Type) Line 587 C++
  20. UnrealEditor-Core.dll!FNamedTaskThread::ProcessTasksNamedThread(int QueueIndex, bool bAllowStall) Line 753 C++
  21. UnrealEditor-Core.dll!FNamedTaskThread::ProcessTasksUntilIdle(int QueueIndex) Line 653 C++
  22. UnrealEditor-Core.dll!FTaskGraphCompatibilityImplementation::ProcessThreadUntilIdle(ENamedThreads::Type CurrentThread) Line 2105 C++
  23. UnrealEditor-RenderCore.dll!GameThreadWaitForTask(const TRefCountPtr<FGraphEvent> & Task, ENamedThreads::Type TriggerThreadIndex, bool bEmptyGameThreadTasks) Line 1213 C++
  24. UnrealEditor-RenderCore.dll!FRenderCommandFence::Wait(bool bProcessGameThreadTasks) Line 1278 C++
  25. UnrealEditor.exe!FEngineLoop::Tick() Line 5424 C++
  26. [Inline Frame] UnrealEditor.exe!EngineTick() Line 62 C++
  27. UnrealEditor.exe!GuardedMain(const wchar_t * CmdLine) Line 183 C++
  28. UnrealEditor.exe!LaunchWindowsStartup(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow, const wchar_t * CmdLine) Line 272 C++
  29. UnrealEditor.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * pCmdLine, int nCmdShow) Line 330 C++
  30. [External Code]

Have Comments or More Details?

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

0
Login to Vote

Unresolved
CreatedNov 21, 2024
UpdatedNov 21, 2024
View Jira Issue