Copyright © 2026 Unity Technologies
Reproduction steps:
1. Create a new project
2. Open UI Library window (GameObject > UI Toolkit > Standard Elements > UI Library…)
3. Press “Filter the controls shown in the library” button and enable “Show Internal Controls” option
4. Double-click Style Rule Inspector Element to create it (Unity > UIToolkit > Editor > Style Rule Inspector) and save UXML file
5. Create any other Standard Element
6. Observe the Console
Actual result: “NullReferenceException: Object reference not set to an instance of an object” error is thrown
Expected result: No warnings or errors are thrown
Reproducible with: 6000.7.0a5
Couldn’t reproduce with: 6000.0.81f1, 6000.3.22f1, 6000.5.8f1, 6000.6.0a6 (No Standard Elements option), 6000.6.0b9, 6000.7.0a4 (No “Filter the controls shown in the library” button)
Reproduced on: macOS Tahoe 26.5 (M4)
Note:
Full error:
NullReferenceException: Object reference not set to an instance of an object UnityEngine.UIElements.Layout.LayoutConfig.get_TransformFlags () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Layout/LayoutConfig.cs:37) UnityEngine.UIElements.BaseVisualElementPanel.get_transformFlags () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Panel.cs:504) UnityEngine.UIElements.BaseVisualElementPanel.get_duringLayoutPhase () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Panel.cs:723) UnityEngine.UIElements.BaseVisualElementPanel.set_duringLayoutPhase (System.Boolean value) (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Panel.cs:726) UnityEngine.UIElements.VisualTreeLayoutUpdater.Update () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/VisualTreeLayoutUpdater.cs:323) UnityEngine.UIElements.VisualTreeUpdater.UpdateVisualTreePhase (UnityEngine.UIElements.VisualTreeUpdatePhase phase) (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/VisualTreeUpdater.cs:146) UnityEngine.UIElements.Panel.ValidateLayout () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Panel.cs:1722) UnityEngine.UIElements.BaseRuntimePanel.Update () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Panel.cs:2080) UnityEngine.UIElements.UIElementsRuntimeUtility.UpdatePanels () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/UIElementsRuntimeUtility.cs:372) UnityEngine.UIElements.UIElementsRuntimeUtilityNative.UpdatePanels () (at /Users/bokken/build/output/unity/unity/Modules/UIElements/Core/Native/UIElementsUtility.bindings.cs:23) UnityEngine.StackTraceUtility:ExtractStringFromExceptionInternal(Object, String&, String&) (at /Users/bokken/build/output/unity/unity/Runtime/Export/Scripting/StackTrace.cs:50)
Issues you vote on will appear here