Search Issue Tracker
Postponed means that the issue was either a feature request or something that requires major refactoring on our side. Since that makes the issue not actionable in the close future we choose to close it as Postponed and add it on our internal roadmaps and technical debt pages instead.
Postponed
Votes
0
Found in
2020.3
2021.1
2021.2
2022.1
2022.1.0a9
Issue ID
1366036
Regression
No
Errors and warnings logged in the Console when calling AssetDatabase methods during OnValidate that reimports Assets
How to reproduce:
1. Open the attached project "CheckConsistencyLoadAssets"
2. In the Project window, select the asset "SelectMe" (Assets/SelectMe.asset)
3. In the Inspector, right-click the header and select "Display the Error!"
4. Inspect the Console window (Window > General > Console)
Expected result: No warnings or errors are displayed in the Console
Actual result: Several warnings and errors are displayed in the Console
Reproducible with: 2020.3.19f1, 2021.1.22f1, 2021.2.0b13, 2022.1.0a9
Could not test with: 2019.4.30f1 (‘AssetDatabase’ does not contain a definition for ‘RegisterCustomDependency’)
Note: in versions starting from 2022.1.0a8, a message is displayed in the Console window alongside the warnings and errors
Errors:
Destroying GameObjects immediately is not permitted during physics trigger/contact, animation event callbacks, rendering callbacks or OnValidate. You must use Destroy instead.
UnityEditor.AssetDatabase:Refresh ()
Warnings:
SendMessage cannot be called during Awake, CheckConsistency, or OnValidate
UnityEngine.GameObject:.ctor (string,System.Type[])
SendMessage cannot be called during Awake, CheckConsistency, or OnValidate
UnityEditor.AssetDatabase:Refresh ()
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
- Crash on ShaderLab::ShaderState::ApplyShaderState when entering Play Mode and calling ShaderWarmup.WarmupShaderFromCollection with a shader that has dynamic_branch
- Crash on operator delete[] when a serializable structure in the System namespace is serialized by a MonoBehaviour
- [macOS] forward and backward mouse buttons are recognized as middle mouse button
- NavMeshModifier.OnEnable/OnDisable gets progressively slower when called repeatedly
- "System.Net.CookieContainer" throws an "ArgumentException" error when using a non-UTF-8 machine locale and hostname
Resolution Note (2022.1.X):
Postponed