Search Issue Tracker
Fixed in 2021.2.X
Votes
0
Found in
2019.4
2019.4.18f1
2020.2
2021.1
2021.2
Issue ID
1307194
Regression
No
Build fails with Object reference not set Exception when Building Android
How to reproduce:
1. Open the attached "HB SB Umpire Training Quest.zip" Project
2. Build the project
Expected Behavior: The project builds without errors
Actual Behavior: The project fails to build with Object null reference exception.
Reproducible with: 2019.4.19f1, 2020.2.3f1, 2021.1.0b4, 2021.2.0a3
Could not test with: 2018.4 since the project has a lot of dependencies that break on downgrade
Note:
- Build error piece(full error in the edits): NullReferenceException: Object reference not set to an instance of an object
UnityEditor.AssemblyReferenceChecker.CollectReferencedAndDefinedMethods (Mono.Cecil.TypeDefinition type, System.Boolean isSystem) (at <bef6d2fbef1348939b77102b4cf6a6e6>:0)
- The issue does not reproduce when building windows standalone, only Android
- Could not reproduce on a newly created Project
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
- Editor crashes on StoredGraphicsBuffer::GetGfxBufferID when VFX Graph property is modified during Play Mode and Application.targetFrameRate is used to limit FPS
- Crash on NVAPI_Thunk when changing Player resolution while HDR display is used and Direct3D12 is set as the graphics API
- Only one out of multiple cameras is shown in the Play Mode while HDR display is used and Direct3D12 is set as the graphics API
- The "Paste Component as New" option is incorrectly displayed as active despite the action being prohibited
- "TLS Allocator ALLOC_TEMP_TLS" errors are thrown when unsuccessfully importing an FBX file
Resolution Note (fix version 2021.2):
The fix is only making the error more actionable to the the user (indicating which assembly / type / method has invalid IL)