StressLevelZero / MarrowSDK-Legacy

MIT License
288 stars 39 forks source link

Asset Warehouse NullReferenceException after loading project a second time #3

Open Floofbutt opened 1 year ago

Floofbutt commented 1 year ago

This is from a fresh install of the SDK on windows 10 64 bit.

I am not sure if this is due to user error or just some per-chance bug. The log will be pasted below and I will include an image of the aforementioned behavior. But this is currently preventing me from fixing a material issue with the avatar I am trying to prepare.

Error Log from unity: NullReferenceException: Object reference not set to an instance of an object SLZ.MarrowEditor.AssetWarehouseTreeView.GetDistinctTagsFromCrates (System.Collections.Generic.List`1[T] pallets) (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseTreeView.cs:223) SLZ.MarrowEditor.AssetWarehouseTreeView.BuildRoot () (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseTreeView.cs:76) UnityEditor.IMGUI.Controls.TreeView+TreeViewControlDataSource.FetchData () (at <1f0be198f5164d2489de92f22c998266>:0) UnityEditor.IMGUI.Controls.TreeViewDataSource.ReloadData () (at <1f0be198f5164d2489de92f22c998266>:0) UnityEditor.IMGUI.Controls.TreeView+TreeViewControlDataSource.ReloadData () (at <1f0be198f5164d2489de92f22c998266>:0) UnityEditor.IMGUI.Controls.TreeViewController.ReloadData () (at <1f0be198f5164d2489de92f22c998266>:0) UnityEditor.IMGUI.Controls.TreeView.Reload () (at <1f0be198f5164d2489de92f22c998266>:0) SLZ.MarrowEditor.AssetWarehouseTreeView..ctor (UnityEditor.IMGUI.Controls.TreeViewState treeViewState) (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseTreeView.cs:39) SLZ.MarrowEditor.AssetWarehouseWindow.b__7_0 () (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseWindow.cs:40) SLZ.Marrow.Warehouse.AssetWarehouse.OnReady (System.Action callbackWhenReady) (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK/SLZ.Marrow.Warehouse/AssetWarehouse.cs:111) Asset warehouse issue

SLZ.MarrowEditor.AssetWarehouseWindow.OnEnable () (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseWindow.cs:36) UnityEditor.EditorWindow:GetWindow() SLZ.MarrowEditor.AssetWarehouseWindow:ShowWindow() (at Library/PackageCache/com.stresslevelzero.marrow.sdk@cf57525691/SLZ.Marrow.SDK.Editor/SLZ.MarrowEditor/AssetWarehouseWindow.cs:396)

Zyphrono commented 1 year ago

Same here. I am on Windows 11 21H2.

Unity_5qHigeUTZT Unity_W9fA6O8eH6

EDIT: I just reloaded the project and now it is working again. Strange...

dotbenj commented 1 year ago

It happened to me once I juste needed to close and re-open the editor to fix it. If it's not helping try re-installing package on fresh project to see if it fixed your issue.

Greased-Scotsman commented 1 year ago

Thanks for the feedback... If you're still having the issue and a Unity restart doesn't fix, can you describe the steps that produced these errors? We'll see if we can track down the cause.

Floofbutt commented 1 year ago

Honestly the only thing I did was leave the asset warehouse open while closing the project then re-opening it. I'm not sure what other conditions may of caused it.

Greased-Scotsman commented 1 year ago

Haven't been able to reproduce this yet, let us know if it's still affecting you

Floofbutt commented 1 year ago

Still happens upon reloading projects. Need to reload multiple times for it to go away or delete palettes and refresh it.

Anthonyg5005 commented 1 year ago

I get "IOException: Access to the path '\?\D:\Unity\Fruits\Assets\AddressableAssetsData' is denied." every time I close and open a project. It's like the sdk corrupts itself after closing the project

CaelThunderwing commented 1 year ago

i just got around the AssetWarehouse is NULL by using "Validate Marrow Project Settings" in Stress Level Zero - > Void Tools

Greased-Scotsman commented 1 year ago

Still happens upon reloading projects. Need to reload multiple times for it to go away or delete palettes and refresh it.

If there are errors in the console as you close the project, they'll re-trigger when you open Unity again. Try validating your Marrow Project settings. Then, make sure that your avatar itself doesn't have some cursed script somewhere in its hierarchy... this is fairly common for avatars that come from VRChat or SFM.

RevOcelotMGS commented 1 year ago

As an FYI, this appears to solely be a MarrowSDK package issue. Reimporting the package on its' own rids of this error quite quickly, without need to reload the project.

Pizzahutlover commented 1 year ago

Same issue has anyone found a fix?