Search Issue Tracker
Fixed in 2022.1.X
Fixed in 2019.4.X, 2020.3.X, 2021.1.X, 2021.2.X
Votes
0
Found in
2019.4
2019.4.18f1
2020.3
2021.1
2021.2
Issue ID
1328065
Regression
No
Null references on Prefab after changes are made to ScriptableObject GUID and public script references
Reproduction steps:
1. Open attached project "NullRef.zip"
2. Open Assets/SampleAsset.asset.meta in a text editor, modify the last character of it's GUID and save the file
3. In Project window, select Assets/GameObject
4. In Inspector window, observe SampleScript component's SA field ("Missing")
5. In Project window, open Assets/SampleScript.cs
6. In Script Editor, add a new public GameObject reference and save the changes
7. In Project window, select Assets/GameObject
8. In Inspector window, observe SampleScript component's SA field ("None")
9. Undo the changes made in Assets/SampleAsset.asset.meta with text editor and save the changes
10. In Inspector window, observe SampleScript component's SA field ("None")
11. In script editor, remove the new field from Assets/SampleScript.cs and save the changes
12. In Inspector window, observe SampleScript component's SA field (reference becomes valid)
13. In script editor, add the field again to Assets/SampleScript.cs again and save the changes
14. In Inspector window, observe SampleScript component's SA field ("None")
15. In Project window, open Assets/GameObject.prefab
16. In Inspector window, observe SampleScript component's SA field (valid when in Prefab mode)
Expected result: The reference to SampleAsset.asset in GameObject.prefab should remain valid before and after steps 11-16
Actual result: The reference to SampleAsset.asset in GameObject.prefab is valid after removing new field and in Prefab mode
Reproducible with: 2019.4.24f1, 2020.3.4f1, 2021.1.2f1, 2021.2.0a13
Could not test with: 2018.4.34f1 (console errors break 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
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note (fix version 2022.1):
Fixed in 2022.1.0a7
Resolution Note (fix version 2021.2):
Fixed in 2021.2.0b13
Resolution Note (fix version 2021.1):
Fixed in 2021.1.25f1
Resolution Note (fix version 2020.3):
Fixed in 2020.3.20f1
Resolution Note (fix version 2019.4):
Fixed in 2019.4.32f1