Search Issue Tracker
Won't Fix
Votes
0
Found in [Package]
1.11.2
Issue ID
ADDR-1946
Regression
Yes
Exceptions are not caught with try-catch block when using AssetReference.LoadSceneAsync with invalid Scene
How to reproduce:
1. Open the attached project's "case_1322452-Project.zip" Scene labeled "SampleScene"
2. Enter the Play Mode
3. Inspect the Console Window
Expected result: Exceptions are caught
Actual result: Exceptions are not caught
Reproducible with: 1.11.2, 1.17.17 (2018.4.34f1, 2019.4.24f1, 2020.3.7f1, 2021.1.6f1, 2021.2.0a15)
Not reproducible with: 1.10.0 (2018.4.34f1, 2019.4.24f1, 2020.3.7f1, 2021.1.6f1, 2021.2.0a15)
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
- Skinned Mesh Renderer with multiple Animator Components does not render when "Optimize Game Objects" is enabled
- [iOS]Certain characters are not displayed when using iOS devices with 18 OS and newer
- Trees do not render in 'Unity Terrain - URP Demo Scene'
- Silent crash when clicking in Scene View in a specific project
- The Player renders black on a Quest headset when MSAA, Post Processing, and Spacewarm depth submission are enabled
Resolution Note:
Because this is an async operation, by the time an exception is hit, it likely cannot be passed up to the calling code. As such, we never attempt to pass it up, but instead catch the exception ourselves and log it. So two notes.
1. Exceptions are indeed caught, they're just also logged, which could make them appear as "not caught"
2. If a user wishes to actively process exceptions, they should do so via the ResourceManager.ExceptionHandler as outlined here https://docs.unity3d.com/Packages/com.unity.addressables@1.17/manual/ExceptionHandler.html