Steps to reproduce:
- Create and open a new project
- Open 'Edit -> Project Settings -> UI Toolkit'
- Enable 'in-scene UI Authoring'
- In Hierarchy, right-click -> UI Toolkit -> Standard Elements -> Visual Element
- Duplicate the VisualElement 10 times
- Select the first VisualElement
- Delete it
- Repeat steps 6-7 in a quick succession
- Observe the Console
Actual results: "NullReferenceException: Object reference not set to an instance of an object
Unity.UIToolkit.Editor.UxmlAssetUtilities.SynchronizePath" is thrown
Expected results: No errors are thrown
Reproducible with versions: 6000.7.0a6
Not reproducible with versions: 6000.6.0b1, 6000.6.1f1, 6000.7.0a5
Can’t test with versions: 6000.0.83f1, 6000.3.24f1 (No UI Authoring in Scene)
Tested on (OS): Windows 11 Pro (25H2)
Notes:
- Reproducible both in main stage and UI stage