NullReferenceException...UnityEditor.PropertyEditor.ClearEditorsAndRebuil()

Issue #926 resolved
Andrew Naimou created an issue
  1. Upon every asset reload (reload scripts, start scene, move assets within Unity, etc.), I receive receive the error listed below:
  2. Unsure how to reproduce it in other projects aside from my own. To reproduce, simply perform an action that reloads assets
  3. Screenshot attached
  4. 2022.2.18f1, but occurred on previous versions of 2022
  5. Version 3.1.12.2
  6. No - Editor Only mode is NOT enabled
  7. Windows 10
NullReferenceException: Object reference not set to an instance of an object
UnityEditor.PropertyEditor.ClearEditorsAndRebuild () (at <10c84b1f46b048e28e06a4f5c75562ed>:0)
System.Reflection.RuntimeMethodInfo.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <cbc72d4a9767498db39486e941a498e3>:0)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.RuntimeMethodInfo.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <cbc72d4a9767498db39486e941a498e3>:0)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at <cbc72d4a9767498db39486e941a498e3>:0)
Sirenix.OdinInspector.Editor.InspectorConfig.UpdateOdinEditors () (at C:/Sirenix/Sirenix Solution/Sirenix.OdinInspector.Editor/Config/InspectorConfig.cs:201)
UnityEngine.Debug:LogException(Exception)
Sirenix.OdinInspector.Editor.InspectorConfig:UpdateOdinEditors() (at C:/Sirenix/Sirenix Solution/Sirenix.OdinInspector.Editor/Config/InspectorConfig.cs:206)
Sirenix.OdinInspector.Editor.<>c:<.cctor>b__0_0() (at C:/Sirenix/Sirenix Solution/Sirenix.OdinInspector.Editor/Utilities/CustomEditorLoader.cs:22)
Sirenix.OdinInspector.Editor.<>c__DisplayClass14_0:<DelayAction>b__4() (at C:/Sirenix/Sirenix Solution/Sirenix.Utilities.Editor/Misc/UnityEditorEventUtility.cs:121)
Sirenix.OdinInspector.Editor.<>c__DisplayClass14_0:<DelayAction>b__1(Int32, Rect) (at C:/Sirenix/Sirenix Solution/Sirenix.Utilities.Editor/Misc/UnityEditorEventUtility.cs:108)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)

Comments (1)

  1. Lucas Schwaner

    Hey, we are unable to reproduce this in newer versions of Odin, and it is most likely fixed in 3.2 and above. If the issue persists, please send reproduction steps or the project so we can reproduce the problem.

  2. Log in to comment