Reference Viewer Crash

Hi,

my engine (5.4) crashes when I try to open the reference viewer for any asset with the attached callstack.

I have no clue why it’s doing that. Most likely it saved something which it is trying to restore that is corrupted. I attached a screenshot of the array where things go wrong.

I have two checkouts of the same Engine/Project. Both are crashing.

I tried deleting the “Saved” folder, “AppData\Roaming\Unreal Engine” as well as “AppData\Local\UnrealEngine” but it did not help.

If you, from that call stack, have any clue what is going on or can point me to something I can debug: Any help is appreciated.

Cheers.

Steps to Reproduce
I right click any asset -> Find References -> Crash

Hello [mention removed]​,

Thanks for the details, I’m going to take a look at the callstack and follow up soon. Could you please confirm if this issue also occurs in an blank new project in UE 5.4?

Best,

Francisco

Hi Francisco,

thanks for the reply. It does indeed also crash if i create a blank project with that engine and try to find references.

Here is the callstack again.

It appears that also the UReferenceViewerSettings inside the SReferenceViewer is null. No clue how that is possible. See SReferenceViewer.cpp L 576.

Cheers

Dominik

UnrealEditor-AssetManagerEditor.dll!TArray<FAssetIdentifier,TSizedDefaultAllocator<32>>::operator=(const TArray<FAssetIdentifier,TSizedDefaultAllocator<32>> & Other) Line 507	C++
 	UnrealEditor-AssetManagerEditor.dll!UEdGraph_ReferenceViewer::SetGraphRoot(const TArray<FAssetIdentifier,TSizedDefaultAllocator<32>> & GraphRootIdentifiers, const UE::Math::TIntPoint<int> & GraphRootOrigin) Line 65	C++
>	UnrealEditor-AssetManagerEditor.dll!SReferenceViewer::SetGraphRootIdentifiers(const TArray<FAssetIdentifier,TSizedDefaultAllocator<32>> & NewGraphRootIdentifiers, const FReferenceViewerParams & ReferenceViewerParams) Line 576	C++
 	UnrealEditor-AssetManagerEditor.dll!FAssetManagerEditorModule::OpenReferenceViewerUI(const TArray<FAssetIdentifier,TSizedDefaultAllocator<32>> SelectedIdentifiers, const FReferenceViewerParams ReferenceViewerParams) Line 759	C++
 	UnrealEditor-AssetManagerEditor.dll!FAssetManagerEditorModule::OpenReferenceViewerUI(const TArray<FName,TSizedDefaultAllocator<32>> SelectedPackages, const FReferenceViewerParams ReferenceViewerParams) Line 772	C++
 	UnrealEditor-AssetManagerEditor.dll!FAssetManagerEditorModule::OnExtendContentBrowserCommands::__l2::<lambda_1>::operator()() Line 939	C++
 	[Inline Frame] UnrealEditor-AssetManagerEditor.dll!Invoke(FAssetManagerEditorModule::OnExtendContentBrowserCommands::__l2::<lambda_1> &) Line 47	C++
 	[Inline Frame] UnrealEditor-AssetManagerEditor.dll!UE::Core::Private::Tuple::TTupleBase<TIntegerSequence<unsigned int>>::ApplyAfter(FAssetManagerEditorModule::OnExtendContentBrowserCommands::__l2::<lambda_1> &) Line 309	C++
 	UnrealEditor-AssetManagerEditor.dll!TBaseFunctorDelegateInstance<void __cdecl(void),FDefaultDelegateUserPolicy,`FAssetManagerEditorModule::OnExtendContentBrowserCommands'::`2'::<lambda_1>>::ExecuteIfSafe() Line 870	C++
 	[Inline Frame] UnrealEditor-Slate.dll!TDelegate<void __cdecl(void),FDefaultDelegateUserPolicy>::ExecuteIfBound() Line 570	C++
 	UnrealEditor-Slate.dll!FUIAction::Execute() Line 139	C++
 	UnrealEditor-Slate.dll!FUICommandList::ExecuteAction(const TSharedRef<FUICommandInfo const ,1> InUICommandInfo) Line 117	C++
 	UnrealEditor-Slate.dll!SMenuEntryBlock::OnClicked(bool bCheckBoxClicked) Line 1158	C++
 	UnrealEditor-Slate.dll!SMenuEntryBlock::OnMenuItemButtonClicked() Line 1118	C++
 	[Inline Frame] UnrealEditor-Slate.dll!Invoke(FReply(SMenuEntryBlock::*)()) Line 66	C++
 	[Inline Frame] UnrealEditor-Slate.dll!UE::Core::Private::Tuple::TTupleBase<TIntegerSequence<unsigned int>>::ApplyAfter(FReply(SMenuEntryBlock::*)() &) Line 309	C++
 	UnrealEditor-Slate.dll!TBaseSPMethodDelegateInstance<0,SMenuEntryBlock,1,FReply __cdecl(void),FDefaultDelegateUserPolicy>::Execute() Line 281	C++
 	[Inline Frame] UnrealEditor-Slate.dll!TDelegate<FReply __cdecl(void),FDefaultDelegateUserPolicy>::Execute() Line 549	C++
 	UnrealEditor-Slate.dll!SButton::ExecuteOnClick() Line 465	C++
 	UnrealEditor-Slate.dll!SButton::OnMouseButtonUp(const FGeometry & MyGeometry, const FPointerEvent & MouseEvent) Line 390	C++
 	UnrealEditor-Slate.dll!SMenuEntryButton::OnMouseButtonUp(const FGeometry & MyGeometry, const FPointerEvent & MouseEvent) Line 434	C++
 	[Inline Frame] UnrealEditor-Slate.dll!FSlateApplication::RoutePointerUpEvent::__l8::<lambda_2>::operator()(const FArrangedWidget &) Line 5293	C++
 	UnrealEditor-Slate.dll!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,`FSlateApplication::RoutePointerUpEvent'::`8'::<lambda_2>>(FSlateApplication * ThisApplication, FEventRouter::FToLeafmostPolicy RoutingPolicy, FPointerEvent EventCopy, const FSlateApplication::RoutePointerUpEvent::__l8::<lambda_2> & Lambda, ESlateDebuggingInputEvent DebuggingInputEvent) Line 442	C++
 	UnrealEditor-Slate.dll!FSlateApplication::RoutePointerUpEvent(const FWidgetPath & WidgetsUnderPointer, const FPointerEvent & PointerEvent) Line 5279	C++
 	UnrealEditor-Slate.dll!FSlateApplication::ProcessMouseButtonUpEvent(const FPointerEvent & MouseEvent) Line 5857	C++
 	UnrealEditor-Slate.dll!FSlateApplication::OnMouseUp(const EMouseButtons::Type Button, const UE::Math::TVector2<double> CursorPos) Line 5813	C++
 	[External Code]	
 	UnrealEditor-Win64-DebugGame.exe!FEngineLoop::Tick() Line 5850	C++
 	[Inline Frame] UnrealEditor-Win64-DebugGame.exe!EngineTick() Line 61	C++
 	UnrealEditor-Win64-DebugGame.exe!GuardedMain(const wchar_t * CmdLine) Line 180	C++
 	UnrealEditor-Win64-DebugGame.exe!LaunchWindowsStartup(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow, const wchar_t * CmdLine) Line 247	C++
 	UnrealEditor-Win64-DebugGame.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * pCmdLine, int nCmdShow) Line 298	C++
 	[External Code]

Hello [mention removed]​,

Thanks for the extra details. I cannot reproduce the crash locally in UE 5.4. Based on the source code and callstack, the crash seems to occur here:

void UEdGraph_ReferenceViewer::SetGraphRoot(const TArray<FAssetIdentifier>& GraphRootIdentifiers, const FIntPoint& GraphRootOrigin)
{
	CurrentGraphRootIdentifiers = GraphRootIdentifiers;
	CurrentGraphRootOrigin = GraphRootOrigin;
        ...
}

It looks like the values for GraphRootIdentifiers or GraphRootOrigin are corrupted and cause the crash when assigned to the member variables via the “=” operator.

In my case, when opening the reference viewer for a new BP, these are the expected values for GraphRootIdentifiers and GraphRootOrigin:

[Image Removed]Could you please share what values are passed to UEdGraph_ReferenceViewer::SetGraphRoot in your case?

Additionally, Settings should never be nullptr. It would be helpful to check if your EditorPerProjectUserSettings.ini under Project/Saved/Config/WindowsEditor contains the following block:

[/Script/AssetManagerEditor.ReferenceViewerSettings]
bEnableCollectionFilter=False
bEnablePluginFilter=False
bIsShowExternalReferencers=False
bFindPathEnabled=False

These are the default ReferenceViewerSettings that the editor should load. If the settings block does not exist then try add it and restart the engine.

If the problem persists then please let’s try to debug how the editor is loading your UReferenceViewerSettings. These are initialized in SReferenceViewer::Construct. You can add a breakpoint there and verify that GetMutableDefault<UReferenceViewerSettings> returns a valid object, similar to the screenshot below.

[Image Removed]Add the breakpoint and try to open the reference viewer window for any asset to debug this value.

Please let me know.

Best,

Francisco

Hi Francisco,

I checked the .ini and found the lines just as you pasted them.

I also stepped through the SReferenceViewer::Construct and the Settings is null right after it should have been initialized.

When I finally arrive at the SReferenceViewer::SetGraphRootIdentifiers the Settings and its fields say “Unable to read Memory”.

Inside the Construct I tried stepping into the GetMutableDefault but was not very successful. The GetDefaultObject is not even hit. But that could also be because the function is inlined.

So i guesss i’m still lost here. :confused:

Best,

Dominik

[Image Removed]

Hi Francisco,

this is what I got right after the settings should have been initialized.

I am indeed using a source build of 5.4.4 with some minor engine modifications. We are rolling out this version to the team. But no one else on the team experiences this problem.

I also tried a 5.4.4 Laucher version. That one also crashes.

I set up a 5.6.1 Launcher version for testing and the reference viewer opens just fine.

So, I’m guessing some setting tied to that specific engine version, that sits outside the project-/engine-directory, must be borked.

Thanks again for your help and patience. Hoping for more tips that help me resolve this mess.

Dominik

Update:

Whatever happened when I opened the reference viewer in 5.6 helped solve the problem. Now the reference viewer opens in 5.4 and after weeks I can finally use my engine again as I’m used to.

Thank you again for your help. Even though I am left with kind of a WTF here. ¯\_(ツ)_/¯

Best,

Dominik

Hello [mention removed]​,

Thanks for the update. Just to clarify: the result of GetMutableDefault<UReferenceViewerSettings>() should appear after Settings is initialized, but you would see it in the result of GetMutableDefault itself via the Autos or Locals tab.

[Image Removed]Could you confirm if you’re using a source build of UE 5.4 or the Launcher-installed version? If it’s the Launcher version, please try a clean install of UE 5.4 and test again in a blank project to help rule out any local corruption.

Please let me know.

Best,

Francisco

Hello [mention removed]​,

Really glad to hear it’s working again! That’s definitely odd. It is possible a shared config or cache file (for example under C:\Users\<User>\AppData\Local\UnrealEngine\) had become corrupted, and opening the Reference Viewer in UE 5.6 forced it to refresh or rebuild.

I’ll go ahead and close the case now but feel free to reply or open a new one if anything else comes up.

Best,

Francisco