Search Issue Tracker
Third Party Issue
Votes
4
Found in
2021.3.34f1
2022.3.17f1
2023.2.6f1
2023.3.0b3
Issue ID
UUM-60503
Regression
No
The Editor freezes on GizmoManager.DrawGizmos Unity's code execution when opening a project
Reproduction steps:
1. Open the attached “repro-project“
2. Observe the Editor freezing on GizmoManager.DrawGizmos Unity’s code execution
Reproducible with: 2021.3.34f1, 2022.3.17f1, 2023.2.6f1, 2023.3.0b3
Reproduced on: Windows 10
Not reproducible on: No other environment tested
Notes:
1. The user reported the freeze eventually leading to a crash with the following error:
”[Assets/Generated/QueenTouchPoints.cs line 40]
GUI Window tried to begin rendering while something else had not finished rendering! Either you have a recursive OnGUI rendering, or the previous OnGUI did not clean up properly.
Crash!!!”
2. The freeze is no longer reproducible after removing the script mentioned in the error
3. In the script OnDrawGizmos() method is being called inside the Update() method, which might be causing recursive OnGUI rendering issues and contributing to the freeze and crash
First few lines of the stack trace:
0x00007FF6A2AEB9E5 (Unity) AddPrimitivesImpl
0x00007FF6A2ADAEBC (Unity) DrawLine
0x00007FF6A0EFD923 (Unity) Gizmos_CUSTOM_DrawLine_Injected
0x0000022DE9C33F55 (Mono JIT Code) (wrapper managed-to-native) UnityEngine.Gizmos:DrawLine_Injected (UnityEngine.Vector3&,UnityEngine.Vector3&)
0x0000022DE9C33E7B (Mono JIT Code) UnityEngine.Gizmos:DrawLine (UnityEngine.Vector3,UnityEngine.Vector3)
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
- "Reset UI Builder Layout" functionality inconsistently changes Canva Size when "Match Game View" is enabled/disabled
- Texture Import Warnings are obscured by other Terrain Layer options in the Inspector
- Burst Inspector middle divider is jittering when resized with the Burst Inspector window docked
- JsonConvert conversion fails trying to call GetCallbackMethodsForType when [OnDeserialized] is used in a class
- Different text alignment in the column header in Entities "System" window
Resolution Note:
The issue is not a problem on the editor side, rather the user code responsible for drawing gizmos is an infinite loop.
QueenTouchPoints.DrawRaycasts has a for loop that iterates from startAngle to endAngle with a step value. All of the parameters being passed into this function are 0, resulting in the loop endlessly running.