Search Issue Tracker

By Design

Votes

0

Found in

2019.2.0a13

2019.3.9f1

2019.4

2020.1

2020.2

Issue ID

1243035

Regression

Yes

Custom AssetImporterEditor Script throws errors when selecting a texture

Asset - Database

-

How to reproduce:
1. Open the attached "1243035 repro" project
2. Select "NewImage.png" from the Assets > AdvancedTextureImporter > ExampleTexture folder

Expected result: no errors are thrown
Actual result: errors stating that the previous instance hasn't been disposed correctly are thrown

Reproducible with: 2019.2.0a13, 2019.2.21f1, 2019.4.0f1, 2020.1.0b13, 2020.2.0a15
Not reproducible with: 2018.4.23f1, 2019.2.0a12

Notes:
-On affected versions the bug doesn't necessarily reproduce on the first selection, deselect and repeat the 2nd step a few times to reproduce.
-Very rarely the Editor crashes after selecting the "NewImage.png"
-The Editor sometimes crashes when recompiling the "TextureImporterEditor.cs" Script
-The full error states: The previous instance of UnityEditor.TextureImporterInspector has not been disposed correctly. Make sure you are calling base.OnDisable() in your AssetImporterEditor implementation.
UnityEditor.Editor:CreateEditor (UnityEngine.Object[],System.Type)
AdvancedTextureImporter.TextureImporterEditor:OnEnable () (at Assets/AdvancedTextureImporter/Scripts/Editors/TextureImporterEditor.cs:22)

  1. Resolution Note (2020.2.X):

    This feature is not officially supported.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.