Search Issue Tracker
Fixed
Votes
0
Found in
2023.2.0b10
2023.3.0a7
Issue ID
UUM-52048
Regression
No
NullReferenceException: SerializedObject errors after altering SO
How to reproduce:
- Download and open [https://github.cds.internal.unity3d.com/unity/rqa-project-nebula/tree/so-errors]
- Open Level1 scene
- In Project view find and open "NPCChatData.asset" in Inpector
- Expand Element 0 > Chat Items
- Enter Play Mode
- Notice the Chat Items list ends up with just 1 item
- Click + sign to add new item
- Exit Play Mode
- Observe Console
Expected result: SO returning to the previous state(Chat Items to full list - restarting the editor it does) and no errors
Actual result: SO stays altered in Inspector after leaving Play Mode and errors start spamming in Console while the SO is selected
Errors:
`NullReferenceException: SerializedObject of SerializedProperty has been Disposed.
UnityEditor.SerializedProperty.get_objectReferenceInstanceIDValue () (at /Users/bokken/build/output/unity/unity/Editor/Mono/SerializedProperty.bindings.cs:1427)
UnityEditor.EditorGUIUtility.ObjectContent (UnityEngine.Object obj, System.Type type, UnityEditor.SerializedProperty property, UnityEditor.EditorGUI+ObjectFieldValidator validator) (at /Users/bokken/build/output/unity/unity/Editor/Mono/EditorGUIUtility.cs:1003)
UnityEditor.UIElements.ObjectField+ObjectFieldDisplay.Update () (at /Users/bokken/build/output/unity/unity/Editor/Mono/UIElements/Controls/ObjectField.cs:182)
UnityEditor.UIElements.ObjectField.UpdateDisplay () (at /Users/bokken/build/output/unity/unity/Editor/Mono/UIElements/Controls/ObjectField.cs:132)
UnityEngine.UIElements.VisualElement+SimpleScheduledItem.PerformTimerUpdate (UnityEngine.UIElements.TimerState state) (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/VisualElementScheduler.cs:346)
UnityEngine.UIElements.TimerEventScheduler.UpdateScheduledEvents () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Scheduler.cs:363)
UnityEngine.UIElements.UIElementsUtility.UnityEngine.UIElements.IUIElementsUtility.UpdateSchedulers () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/UIElementsUtility.cs:273)
UnityEngine.UIElements.UIEventRegistration.UpdateSchedulers () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/UIElementsUtility.cs:105)
UnityEditor.RetainedMode.UpdateSchedulers () (at /Users/bokken/build/output/unity/unity/Modules/UIElementsEditor/RetainedMode.cs:55)`
Reproduced with: 2023.2.0b11, 2023.3.0a7 on MacOS 13.6
Could not downgrade the project to test earlier versions
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Some UXML Template Asset foldouts appear enabled when all fields inside are disabled
- URP Terrain Demo crash on burst_signal_handler after Generating lighting
- Project window button icons are poorly visible and their shades differ in Light theme
- GC.Alloc called by HDRenderPipeline.LensFlareMergeOcclusionDataDrivenPass() when playing the default HDRP Sample Template project
- Automatic LOD fails and SRP Batcher incompatibility occurs when using spline-based quad-topology meshes
Resolution Note:
Fixed by https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-39898