Search Issue Tracker
Not Reproducible
Votes
2
Found in
2021.3.44f1
2022.3.48f1
6000.0.21f1
6000.1.0a7
6000.2.0a1
Issue ID
UUM-82891
Regression
No
IProcessSceneWithReport is not executed when used with Scenes in the Addressables Build
How to reproduce:
1. Open the attached project "IProcessSceneWithReportBug.zip"
2. Build the project
Expected results: A message is logged that AddressablesScene is being processed
Actual results: Only "Stripping development only objects from build in scene SampleScene" is logged
Reproducible with: 2021.3.44f1, 2022.3.48f1, 6000.0.21f1
Reproducible on: Windows 11 23H2
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
- Unity CIL Linker fails on Player build when persistent listeners have "<" and ">" in their XML attribute names
- ”Lighting data asset ‘LightingData’ is incompatible with the current Unity version…” warnings are thrown when saving Indoors (URP) and Outdoors (URP) Scenes as Scene Templates
- [iOS] The screen blinks when transitioning from custom to Unity splash screen
- [macOS] ”Ignoring depth surface load action as it is memoryless” warnings are thrown when taking Game View Snapshot
- UI Builder Inspector scrolls back up when changes on an expanded but not fully displayed Inspector tab are saved
Resolution Note:
OnProcessScene does get called for addressable scenes when an Addressables build occurs. It's just returning early in the user script because when Addressables are built, the BuildReport parameter is null.
The BuildReport object is used when a player build occurs, so when an Addressables build occurs separately from a Player build (i.e. building Addressables via the Default Build script menu) the BuildReport object is null. If the "Build Addressables on Player Build" setting is enabled, an Addressables build will be performed before the player build. So in this case the BuildReport object will also be null during the Addressables build.
Note that when an Addressables build has run it will be cached. The cached build data will be used for future builds and if no content has changed it's possible that the addressable scene won't be re-processed.
UnityEditor.EditorUserBuildSettings.development can be used instead of getting the info from the BuildReport object.