Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Odin inspector 3 not supported (UnityEngine.ExitGUIException) #43

Closed
tamarillostudio opened this issue Nov 2, 2020 · 15 comments
Closed
Labels
bug Something isn't working

Comments

@tamarillostudio
Copy link

Odin inspector has been updated.
An exception occurs on asset inspector.

@issue-label-bot
Copy link

Issue-Label Bot is automatically applying the label bug to this issue, with a confidence of 0.91. Please mark this comment with 👍 or 👎 to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

@issue-label-bot issue-label-bot bot added the bug Something isn't working label Nov 2, 2020
@favoyang
Copy link
Owner

favoyang commented Nov 2, 2020

Please provide

  • com.unity.addresasbles version
  • com.littlebigfun.addressable-importer version
  • odin version
  • exception details

@favoyang
Copy link
Owner

favoyang commented Nov 2, 2020

@Mefodei ODIN related issue, guess you may want to have a look?

@tamarillostudio
Copy link
Author

  • com.unity.addresasbles version : 1.16.7
  • com.littlebigfun.addressable-importer version : 0.9.3
  • odin version : 3.0.1.0
  • exception details
    it occurs on click save button. It looks not affect save function.
    UnityEngine.ExitGUIException: Exception of type 'UnityEngine.ExitGUIException' was thrown.
    at Sirenix.OdinInspector.Editor.InspectorProperty.Draw (UnityEngine.GUIContent defaultLabel) [0x00493] in X:\Repositories\sirenix-development\Sirenix Solution\Sirenix.OdinInspector.Editor\Core\InspectorProperty.cs:837
    at Sirenix.OdinInspector.Editor.PropertyTree.DrawProperties () [0x00019] in X:\Repositories\sirenix-development\Sirenix Solution\Sirenix.OdinInspector.Editor\Core\PropertyTree.cs:485
    at Sirenix.OdinInspector.Editor.PropertyTree.Draw (System.Boolean applyUndo) [0x00007] in X:\Repositories\sirenix-development\Sirenix Solution\Sirenix.OdinInspector.Editor\Core\PropertyTree.cs:389
    at UnityAddressableImporter.Editor.Helper.AddressableImporterFilterOdinHandler.Draw () [0x0000f] in /TestProject/Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/OdinSupport/AddressableImporterFilterOdinHandler.cs:56
    UnityEngine.Debug:LogError(Object)
    UnityAddressableImporter.Editor.Helper.AddressableImporterFilterOdinHandler:Draw() (at Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/OdinSupport/AddressableImporterFilterOdinHandler.cs:60)
    UnityAddressableImporter.Editor.Helper.AddressableImporterOdinHandler:DrawInspectorTree(String) (at Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/OdinSupport/AddressableImporterOdinHandler.cs:49)
    UnityAddressableImporter.Editor.Helper.AddressableImporterOdinHandler:Draw() (at Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/OdinSupport/AddressableImporterOdinHandler.cs:26)
    UnityAddressableImporter.Helper.Internal.AddressableImportSettingsEditor:DrawBaseEditor() (at Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/Helper/AddressableImportSettingsEditor.cs:57)
    UnityAddressableImporter.Helper.Internal.AddressableImportSettingsEditor:OnInspectorGUI() (at Library/PackageCache/com.littlebigfun.addressable-importer@0.9.3/Editor/Helper/AddressableImportSettingsEditor.cs:42)
    UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

github-actions bot pushed a commit that referenced this issue Dec 18, 2020
## [0.9.4](v0.9.3...v0.9.4) (2020-12-18)

### Bug Fixes

* initial null exception error when ODIN is enabled (refs [#43](#43)) ([f8d9bba](f8d9bba))
@favoyang
Copy link
Owner

favoyang commented Dec 18, 2020

Hi @tamarillostudio,

Sorry for the long delay. I have made a simple change related to ODIN (f8d9bba), but it only affects the initial importer error.

I don't have an issue when hit the save button.

  • com.unity.addresasbles version : 1.16.15
  • com.littlebigfun.addressable-importer version : 0.9.4
  • ODIN version : 3.0.2
  • Unity 2020.2.0f1

Could you give 0.9.4 a try and also upgrade ODIN to 3.0.2?

@Mefodei
Copy link
Contributor

Mefodei commented Dec 18, 2020

@Mefodei ODIN related issue, guess you may want to have a look?

Yes, i will try to check this one

@Mefodei
Copy link
Contributor

Mefodei commented Dec 22, 2020

That issue on Odin inspector side. They already fix that in v. 3.0.2

@favoyang
Copy link
Owner

@Mefodei thanks for verifying the issue. Issue closed.

@favoyang
Copy link
Owner

We have a new duplicated new issue #46. I tested with

  • addressables 1.16.19
  • odin 3.0.5.0
  • importer 0.9.4

I still get the same error.

UnityEngine.ExitGUIException: Exception of type 'UnityEngine.ExitGUIException' was thrown.

I checked related odin patch notes: https://odininspector.com/patch-notes, since 3.0.2

Fix:

  • GUIUtility.ExitGUI() is now called after all button clicks, meaning that button methods that invalidate the GUI state should no longer cause a multitude of exceptions related to layout and other GUI states to be thrown after they're done executing.

It seems that we could just ignore the issue.

        public void Draw()
        {
            try
            {
                FilterRules(_searchFilter);
                _drawerTree.Draw();
                ApplyChanges();
            }
            catch (Exception e)
            {
                Debug.LogError(e);
            }
        }

=> 
        public void Draw()
        {
                FilterRules(_searchFilter);
                _drawerTree.Draw();
                ApplyChanges();
        }

Thought?

@favoyang favoyang reopened this May 15, 2021
@favoyang favoyang changed the title Odin inspector 3 not supported. Odin inspector 3 not supported (UnityEngine.ExitGUIException) May 15, 2021
@Mefodei
Copy link
Contributor

Mefodei commented May 15, 2021 via email

@favoyang
Copy link
Owner

@Mefodei

Thanks for the quick reply! Will that fix the issue entirely? Please submit a PR, I would like to test it.

I think we can force odin 3 and drop version 2 support.

@Mefodei
Copy link
Contributor

Mefodei commented May 15, 2021 via email

@favoyang
Copy link
Owner

@Mefodei I muted ODIN UnityEngine.ExitGUIException error temporarily in b4cb7cf.

@Mefodei
Copy link
Contributor

Mefodei commented May 16, 2021

@favoyang
#53

@favoyang
Copy link
Owner

Closed by #53

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants