Search Issue Tracker
Duplicate
Votes
0
Found in [Package]
1.0.0-preview.18
Issue ID
1403078
Regression
No
[UI Builder] errors when adding custom font reference to themed stylesheet (TSS)
Reproduction steps:
1. Open the user's project
2. Open UI Builder (Window > UI Toolkit > UI Builder)
Expected result: no errors
Actual result: 2 errors:
1st error - Unexpected recursive transfer of scripted class. 'BuilderDocument' is being transferred while trying to transfer 'LiberationSans SDF'
2nd error - UnityException: get_shader can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
Reproducible with: 1.0.0-preview.15 (2021.2.0b15), 1.0.0-preview.16 (2021.2.0b16), 1.0.0-preview.17 (2021.2.0f1), Built-in (2021.2.13f1), Built-in (2022.1.0b9), Built-in (2022.2.0a4)
Couldn't test with: 1.0.0-preview.18 (2019.4.36f1), 1.0.0-preview.18 (2020.3.30f1), 1.0.0-preview.10 (2021.2.0b1), 1.0.0-preview.14 (2021.2.0b10), 1.0.0-preview.18 (2022.1.0a15) (package errors when converting the project)
Note: for 2022.2.0a4 2nd error starts with "GetName" instead of "get_shader"
Comments (2)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- SystemInfo.get_graphicsDeviceName() is generating garbage GC Alloc when using Metal graphics API
- Crash on D3D12CommonShader::ApplyGpuProgram when attaching material which samples "_UnityFBInput0" to "Full Screen Pass Renderer Feature" Component
- SpeedTree meshes and objects count differs when comparing the numbers in the Player with the Editor
- Model and Prefab Preview icons are not updated after upgrading associated Materials to URP
- Game view is rendered white when viewing the Editor with HDR display and Post Proccesing is enabled on the Main Camera with 2D URP
unity_3367D96D13D8115F6F69
May 15, 2025 20:35
Encountering this still in 6.0000.441f
MrLucid72
Nov 24, 2023 02:43
If this is a duplicate, where is it? I couldn't find it -- this still happens in Unity 2022.3.9f1. Someone seems to have mismarked it as dupe?