Search Issue Tracker
By Design
Votes
0
Found in
2019.4
2020.3
2021.2
2021.2.5f1
2022.1
2022.2
Issue ID
1385979
Regression
No
Runtime helper generated GameObjects are not added to main thread list when using Parallel.For
How to reproduce:
1. Open the user's project "TestCSharp8.zip"
2. Press Play and observe the Console Window
Expected result: Generated GameObjects are added to the list
Actual result: Generated GameObjects are not added to the list
Reproducible with: 2019.4.36f1, 2020.3.30f1, 2021.2.14f1, 2022.1.0b10, 2022.2.0a6
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
- Fixing Message Loss in UMPE During Domain Reload
- The Editor freezes when ScheduleReadOnly of IJobParallelForTransform with dependency is used
- Text is truncated in the Inspector when the display scale is set to 150%
- CancellationTokenSource(<timeout>) has incorrect cancellation status when used in WebGL Player
- VFX property value names are cut off when properties with 'Arc' are viewed in the VFX Blackboard
Resolution Note:
This is a user code issue: the RuntimeHelper.RunOnMainThread does not execute synchronously: it put the action in a queue which is run on each update of the singleton scriptable object. So the GameObjects are actually added during next frame, and are not yet there at the end of the Awake message.