Search Issue Tracker

Fixed

Fixed in 2023.2.15f1, 6000.0.0b11

Votes

0

Found in

2023.2.8f1

2023.3.0b7

6000.0.0b11

Issue ID

UUM-61722

Regression

No

“UnityException: CreateScriptableObjectInstanceFromType can only be called from the main thread" errors are thrown when the VisualTreeAsset layout has text and it is assigned to uiDocument.visualTreeAsset property

--

-

Reproduction steps:
1. Open the attached “Project” project
2. Open the “Assets/Scenes/BootstrapScene.unity” Scene
3. Enter the Play Mode
4. Observe the Console Window

Expected result: No error is thrown
Actual result: Two “UnityException: CreateScriptableObjectInstanceFromType can only be called from the main thread" errors are thrown

Reproducible with: 2023.2.8f1
Could not test with: 2021.3.34f1 (“error CS0246” and two “error CS0115” compilation errors), 2022.3.19f1 (“error CS0246: The type or namespace name 'UxmlAttributeConverter<>' could not be found” compilation error), 2023.3.0b4 (“error CS0101: The namespace '<global namespace>' already contains a definition for 'IronSource'“ compilation error)

Reproducible on: macOS Sonoma 14.1.2 (Intel), Windows 10 (user’s)
Not reproducible on: No other environment tested

Note: The errors are thrown when exciting the Play Mode as well

  1. Resolution Note (fix version 6000.0.0b11):

    Fixed exception "CreateScriptableObjectInstanceFromType can only be called from the main"

  2. Resolution Note (fix version 2023.2.15f1):

    Fixed exception "CreateScriptableObjectInstanceFromType can only be called from the main"

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.