Search Issue Tracker
Fixed in 5.4.0
Votes
0
Found in
5.4.0b5
Issue ID
770153
Regression
No
[ExecuteInEditMode] Calling DestroyImmediate in OnEnable crashes Unity
Steps to reproduce:
1. Open attached project
2. In hierarchy, create empty game object and make sure that its Inspector is visible
3. Drag NewBehaviourScript on it and notice error that script can't be added and, when clicking OK, m_InstanceID != 0
4. Create new empty game object but this time make sure that its Inspector isn't visible (object isn't selected)
5. Drag NewBehaviourScript on it and observe a crash
Long story short: if object is selected and inspector is visible - errors, if object isn't selected - crash
Reproduced with: 5.2.4p1, 5.3.2p3, 5.4.0b6
Comments (2)
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
- [WebGPU] error with compute shader and read-only RWTexture
- Capacity-size memory is copied instead of Length-size when using UnsafeUtility.memCpy()
- Console displays "SerializedObjectNotCreatableException: Object at index 0 is null" error during Unity theme change while "Tile Palette" window is opened
- Details are not shown when Error Message is still selected after changing Log Entry Count in the Console
- Disabling Unity VCS in Project Settings unfocuses the Project Settings Window
x4000
Jun 24, 2016 13:23
Note: the problems I were having are now fixed in unity 5.3.5p5. I was seeing m_InstanceID != 0 issues, which I was assuming were related to this, but it may actually have been the Threadpool issues that were fixed there. Either way, b21 and b22 did not have the issue, but 5.3.5p4 did.
x4000
Jun 22, 2016 12:51
Is this something that we could get int the next 5.3 branch patch? So far as I can tell, this is only in the 5.4 patch notes, and this is affecting a project I'm working on. Upgrading to 5.4 resolves this issue, but then of course there are new issues arising from the fact that 5.4 is beta.