When using the publishing tool in Maya, I was constantly reminded “AttributeError: module ‘typing’ has no attribute ‘runtime_checkable’'” and I didn’t know how to deal with him
Hello,
Does this error happen in other DCCs ?
Does it used to work before some update ?
This looks like we’re using an attribute of the typing module that is not present in that Python version yet - so we may have backwards compatibility issues.
Maya 2022 is Python 3.7.7 I believe.
The typing.runtime_checkable
is added in Python 3.8.
So yes, if that is present in code that runs in Maya we have a compatibility issue.
Unfortunately it seems to come from bidict
dependency and I’m not sure where that originates from. It may be one of the ayon-kitsu dependencies that does not like Py 3.7 anymore. Which seems to come from socketio.basemanager
in usage.
@Danell Any chance you’ve seen this before?
@liuyang199706 If you could provide your full log (you can export a JSON report from the publisher UI) we could look further into the stack trace and maybe pinpoint better where it originates from.
Workaround for now could be:
- Disable Ayon Kitsu module
- Or use a newer version of Maya that is Python 3.8 or higher (e.g. Maya 2024 is 3.9 I think)
{
"crashed_file_paths": {
"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\deadline_0.2.2\\ayon_deadline\\plugins\\publish\\submit_max_deadline.py": "Traceback (most recent call last):\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\pipeline\\publish\\lib.py\", line 257, in publish_plugins_discover\n module = import_filepath(abspath, mod_name)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\lib\\python_module_tools.py\", line 38, in import_filepath\n module_loader.exec_module(module)\n File \"<frozen importlib._bootstrap_external>\", line 728, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\deadline_0.2.2\\ayon_deadline\\plugins\\publish\\submit_max_deadline.py\", line 18, in <module>\n from ayon_max.api.lib import (\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\max_0.2.1\\ayon_max\\api\\__init__.py\", line 4, in <module>\n from .pipeline import (\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\max_0.2.1\\ayon_max\\api\\pipeline.py\", line 17, in <module>\n from ayon_max.api.menu import AYONMenu\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\max_0.2.1\\ayon_max\\api\\menu.py\", line 5, in <module>\n from pymxs import runtime as rt\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\nModuleNotFoundError: No module named 'pymxs'\n",
"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\collect_kitsu_entities.py": "Traceback (most recent call last):\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\pipeline\\publish\\lib.py\", line 257, in publish_plugins_discover\n module = import_filepath(abspath, mod_name)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\lib\\python_module_tools.py\", line 38, in import_filepath\n module_loader.exec_module(module)\n File \"<frozen importlib._bootstrap_external>\", line 728, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\collect_kitsu_entities.py\", line 2, in <module>\n import gazu\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\__init__.py\", line 6, in <module>\n from . import events\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\events.py\", line 10, in <module>\n import socketio\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\__init__.py\", line 3, in <module>\n from .manager import Manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\manager.py\", line 4, in <module>\n from . import base_manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\base_manager.py\", line 4, in <module>\n from bidict import bidict, ValueDuplicationError\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\__init__.py\", line 59, in <module>\n from ._abc import BidirectionalMapping as BidirectionalMapping\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_abc.py\", line 22, in <module>\n from ._typing import KT\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_typing.py\", line 24, in <module>\n @t.runtime_checkable\nAttributeError: module 'typing' has no attribute 'runtime_checkable'\n",
"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\integrate_kitsu_note.py": "Traceback (most recent call last):\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\pipeline\\publish\\lib.py\", line 257, in publish_plugins_discover\n module = import_filepath(abspath, mod_name)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\lib\\python_module_tools.py\", line 38, in import_filepath\n module_loader.exec_module(module)\n File \"<frozen importlib._bootstrap_external>\", line 728, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\integrate_kitsu_note.py\", line 4, in <module>\n import gazu\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\__init__.py\", line 6, in <module>\n from . import events\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\events.py\", line 10, in <module>\n import socketio\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\__init__.py\", line 3, in <module>\n from .manager import Manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\manager.py\", line 4, in <module>\n from . import base_manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\base_manager.py\", line 4, in <module>\n from bidict import bidict, ValueDuplicationError\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\__init__.py\", line 59, in <module>\n from ._abc import BidirectionalMapping as BidirectionalMapping\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_abc.py\", line 22, in <module>\n from ._typing import KT\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_typing.py\", line 24, in <module>\n @t.runtime_checkable\nAttributeError: module 'typing' has no attribute 'runtime_checkable'\n",
"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\integrate_kitsu_review.py": "Traceback (most recent call last):\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\pipeline\\publish\\lib.py\", line 257, in publish_plugins_discover\n module = import_filepath(abspath, mod_name)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\lib\\python_module_tools.py\", line 38, in import_filepath\n module_loader.exec_module(module)\n File \"<frozen importlib._bootstrap_external>\", line 728, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\integrate_kitsu_review.py\", line 2, in <module>\n import gazu\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\__init__.py\", line 6, in <module>\n from . import events\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\events.py\", line 10, in <module>\n import socketio\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\__init__.py\", line 3, in <module>\n from .manager import Manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\manager.py\", line 4, in <module>\n from . import base_manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\base_manager.py\", line 4, in <module>\n from bidict import bidict, ValueDuplicationError\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\__init__.py\", line 59, in <module>\n from ._abc import BidirectionalMapping as BidirectionalMapping\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_abc.py\", line 22, in <module>\n from ._typing import KT\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_typing.py\", line 24, in <module>\n @t.runtime_checkable\nAttributeError: module 'typing' has no attribute 'runtime_checkable'\n",
"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\other_kitsu_log_out.py": "Traceback (most recent call last):\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\pipeline\\publish\\lib.py\", line 257, in publish_plugins_discover\n module = import_filepath(abspath, mod_name)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\core_0.4.0\\ayon_core\\lib\\python_module_tools.py\", line 38, in import_filepath\n module_loader.exec_module(module)\n File \"<frozen importlib._bootstrap_external>\", line 728, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\addons\\kitsu_1.2.2\\ayon_kitsu\\plugins\\publish\\other_kitsu_log_out.py\", line 2, in <module>\n import gazu\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\__init__.py\", line 6, in <module>\n from . import events\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\gazu\\events.py\", line 10, in <module>\n import socketio\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\__init__.py\", line 3, in <module>\n from .manager import Manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\manager.py\", line 4, in <module>\n from . import base_manager\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\socketio\\base_manager.py\", line 4, in <module>\n from bidict import bidict, ValueDuplicationError\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\__init__.py\", line 59, in <module>\n from ._abc import BidirectionalMapping as BidirectionalMapping\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_abc.py\", line 22, in <module>\n from ._typing import KT\n File \"C:\\Program Files\\Autodesk\\Maya2022\\Python37\\lib\\site-packages\\shiboken2\\files.dir\\shibokensupport\\__feature__.py\", line 142, in _import\n return original_import(name, *args, **kwargs)\n File \"C:\\Users\\Administrator\\AppData\\Local\\Ynput\\AYON\\dependency_packages\\ayon_2406251801_windows.zip\\dependencies\\bidict\\_typing.py\", line 24, in <module>\n @t.runtime_checkable\nAttributeError: module 'typing' has no attribute 'runtime_checkable'\n"
}
}
The log provided is just the crashed
files and seems to be missing a large part of the “publish report”.
There should be button, bottom left of publisher UI after validating or publishing that can “Export” the report.
It should provide a JSON file that you can add as attachment here.