Search Issue Tracker
Third Party Issue
Votes
0
Found in
2022.3.58f1
6000.0.38f1
6000.1.0b6
6000.2.0a3
Issue ID
UUM-97401
Regression
No
Task status is "WaitingForActivation" when awaiting a faulted task inside that task
Reproduction steps:
1. Open the attached “IN-92069” project
2. Execute the test (Tools > Run Test)
3. Observe the Console window
Expected result: “Task.Status” is “Faulted” and assertion is not printed
Actual result: “Task.Status” is “WaitingForActivation” and assertion is outputted as failed
Reproducible with: 2022.3.58f1, 6000.0.38f1, 6000.1.0b6, 6000.2.0a3
Reproducible on: Windows 10, Windows 11 (user)
Not reproducible on: No other environment tested
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
- Memory leak occurs when focused on Player while using Direct3D12
- var VisionOSEDRHeadromm has a comma instead of a dot when building with Metal Rendering App Mode and local OS localization is set to German
- IAP Catalog remove product “x” and add product “+” buttons are not consistent with other remove and add buttons in the Editor
- Performance issues in Play Mode when quickly hovering the mouse cursor over Hierarchy GameObjects
- Frame Debugger displays incorrect output when FidelityFX Super Resolution or Spatial-Temporal Upscaler is used with Temporal Anti-aliasing or Subpixel Morphological Anti-aliasing
Resolution Note:
The issue here is in user code:
```
var task = StartProcess();
Thread.Sleep(1000);
Debug.Log(task.Status); // WaitingForActivation
Debug.Assert(task.Status != TaskStatus.WaitingForActivation); // Assertion failed
```
The Thread.Sleep call here is blocking the main thread, making the await Task.Delay() call never resume. So Task1 is actually blocked before it can raise its exception.
The outmost task (the one generated by the async state machine as a continuation to the Task.Delay call) is thus in WaitingForActivation state as it is supposed to resume on main thread, but can't.