OctoPrint-FilamentManager icon indicating copy to clipboard operation
OctoPrint-FilamentManager copied to clipboard

Plugin fail to load on new system setup using python 3.10

Open jaketri opened this issue 3 years ago • 4 comments

It look like issue is with old version of sqlalchemy which use removed/deprecated attribute.

Here is copy/paste section from octoprint.log with the error:

2022-01-12 20:07:41,369 - octoprint.plugin.core - ERROR - Error loading plugin filamentmanager
Traceback (most recent call last):
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint/plugin/core.py", line 1291, in _import_plugin
    module = _load_module(module_name, spec)
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint/plugin/core.py", line 68, in _load_module
    return imp.load_module(name, f, filename, details)
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint/vendor/imp.py", line 238, in load_module
    return load_package(name, filename)
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint/vendor/imp.py", line 212, in load_package
    return _load(spec)
  File "<frozen importlib._bootstrap>", line 719, in _load
  File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 883, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint_filamentmanager/__init__.py", line 17, in <module>
    from .data import FilamentManager
  File "/home/octoprint/venv/lib/python3.10/site-packages/octoprint_filamentmanager/data/__init__.py", line 13, in <module>
    from sqlalchemy.engine.url import URL
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/__init__.py", line 9, in <module>
    from .sql import (
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/__init__.py", line 8, in <module>
    from .expression import (
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/expression.py", line 34, in <module>
    from .functions import func, modifier, FunctionElement, Function
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/functions.py", line 11, in <module>
    from . import sqltypes, schema
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/sqltypes.py", line 17, in <module>
    from . import elements
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/elements.py", line 16, in <module>
    from . import type_api
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/type_api.py", line 16, in <module>
    from .base import SchemaEventTarget
  File "/home/octoprint/venv/lib/python3.10/site-packages/sqlalchemy/sql/base.py", line 49, in <module>
    class _DialectArgView(collections.MutableMapping):
AttributeError: module 'collections' has no attribute 'MutableMapping'

jaketri avatar Jan 13 '22 01:01 jaketri

Based on comment from #23 I tried to force SQLAlchemy update to 1.3.23. I can confirm that plugin is working fine on python 3.10.1 after the SQLAlchemy update to 1.3.23 !

jaketri avatar Jan 13 '22 04:01 jaketri

hey, i tryed to update but still the same issue

mrcsdl avatar Mar 24 '22 15:03 mrcsdl

Running Octoprint 1.8.0RC2 & Python 3.10.4

Same - I restored my backup to a diff PC from a pi. Running Python3.10 and this plugin refuses to install. It appears as if it does but I get a pop-up saying 'unknown' plugin installed. Still does not show in the installed plug-in list.

doc-jay avatar Mar 27 '22 19:03 doc-jay

I can confirm this issue. Restore Backups from OctoPi 1.7.x to actual RC wont work for me either

daniel-volz avatar Apr 08 '22 08:04 daniel-volz