Copyright © 2026 Unity Technologies
Fixed the issue where the default data was not being sync with generic object types causing an unwanted undo call on first use.
Reproduction steps:
1. Open the user-attached “UndetectedUxmlChanges.zip“ project
2. Open the “Assets” > “SerializedPropertyIssue” > “NewUXMLTemplate.uxml” file from the Project window (UI Builder window should open)
3. Click on the “Project” button under the Library of the UI Builder window
4. Drag the “Element” into the Hierarchy of the UI Builder window
5. Expand the “Attributes“ > “M_Container” > “M_value” > “M_value” in the Inspector of the UI Builder window
6. Type anything into the “Path” field
Expected result: No error is displayed in the Console
Actual result: “Assertion failed on expression: '!m_IsUndoing'“ error gets displayed in the Console
Reproducible with: 2023.3.0a6, 2023.3.0a11
Not reproducible with: 2023.2.0b14, 2023.3.0a5
Could not test with: 2021.3.31f1, 2022.3.11f1, 2023.1.17f1 (missing assembly references for UnityEngine.UIElements and UnityEditor.UIElements namespaces)
Reproduced on: Windows 11 Pro (22H2)
Not reproduced on: No other environment tested
Notes:
Full error message (2023.3.0a8 and newer):
Assertion failed on expression: '!m_IsUndoing'
UnityEngine.StackTraceUtility:ExtractStackTrace ()
Unity.UI.Builder.BuilderUxmlAttributesView:ProcessBatchedChanges ()
UnityEngine.UIElements.UIEventRegistration:UpdateSchedulers ()
Unity.UI.Builder.BuilderUxmlAttributesView:OnUndoRedoPerformed ()
UnityEditor.Undo:Internal_CallUndoRedoPerformed ()
Unity.UI.Builder.BuilderUxmlAttributesView:ProcessBatchedChanges ()
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
Full error message (2023.3.0a6 and 2023.3.0a7):
InvalidOperationException: Collection was modified; enumeration operation may not execute.
System.Collections.Generic.List{{1+Enumerator[T].MoveNextRare () (at <e83baa97766c48ccb8f12fd8854cf705>:0) System.Collections.Generic.List}}1+Enumerator[T].MoveNext () (at <e83baa97766c48ccb8f12fd8854cf705>:0)
UnityEditor.UIElements.Bindings.SerializedObjectBindingContext.UpdateTrackedProperties () (at <fc1aaba3017143eea21e9846e942faaa>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)
Issues you vote on will appear here