Search Issue Tracker
Fixed in 2020.2.X
Votes
0
Found in
2019.1.0a11
2019.3
2019.3.4f1
2020.1
2020.2
Issue ID
1248984
Regression
Yes
Editor crashes on Scripting::CreateEngineScriptableObject when creating Custom Editor Window in ScriptableImporter
Reproduction steps:
1. Open the attached "case_1248984.zip" project
-- Observe the crash
Reproduces on: 2019.1.0a11, 2019.2.0a1, 2019.3.14f1, 2020.1.0b9, 2020.2.0a11
Not reproducible with: 2018.4.23f1, 2019.1.0a10 (exception is thrown instead of crashing: "UnityException: ScriptableObject.ctor is not allowed to be called from a script constructor (or instance field initializer). Called from 'ArtomatixMaterialImporter'")
Notes:
- removing "private static readonly MaterialModalWindow window = new MaterialModalWindow();" in ArtomatixMaterialImporter.cs (line 9) stops Editor from crashing
- in some versions (especially in older versions like 2019.1) instead of crashing when opening the project, it silently crashes when reimporting "Materials\test.amtl" in the Project window
First lines of the stack trace:
0x00007ff64e34c6e7 (Unity) Scripting::CreateEngineScriptableObject
0x00007ff64e5793aa (Unity) ScriptableObject_CUSTOM_CreateScriptableObject
0x00000242ae29f5c7 (Mono JIT Code) (wrapper managed-to-native) UnityEngine.ScriptableObject:CreateScriptableObject (UnityEngine.ScriptableObject)
0x00000242ae29f483 (Mono JIT Code) UnityEngine.ScriptableObject:.ctor ()
0x00000242b05be6eb (Mono JIT Code) UnityEditor.EditorWindow:.ctor ()
<...>
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
- Channel remapping dropdown in the Terrain Layer does not open when clicked on the title
- The Editor freezes indefinitely when a large number of elements are entered in the Subgraphs or Categories lists
- Some Visual Effects package Assets links to documentation are not working
- Heatmap asset’s documentation button in the Inspector window leads to “Sorry... that page seems to be missing!” page when clicked
- Crash on MonoBehaviour::CallMethodIfAvailable when performing various actions
Resolution Note (fix version 2020.2):
Fixed in: 2019.3.15f1, 2020.1.0b10, 2020.2.0a12