Search Issue Tracker
Fixed in 2022.3.12f1
Fixed in 2023.3.0a10
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
- Polyspatial Material swap set animations are not firing when used in Play Mode and Players
- Incomplete shortcuts are displayed in the "Set" dropdown in Visual Effects Graph VFX Control subwindow
- Version change sub-window closes automatically when "Add Modules" subwindow is closed
- RenderTexture content from 'Depth Only' camera is not rendered correctly on UI RawImage when Multithreaded Rendering is enabled on specific MediaTek devices.
- Weight Brush Overlay text is clipped in Sprite Editor
Resolution Note (fix version 2022.3.12f1):
Fixed by https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-39898
Resolution Note (fix version 2023.3.0a10):
Fixed by https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-39898