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

Doesn't work with python 3.10 -- import collectors is removed in 3.10 #1640

Closed
fryfrog opened this issue Dec 13, 2021 · 7 comments
Closed

Doesn't work with python 3.10 -- import collectors is removed in 3.10 #1640

fryfrog opened this issue Dec 13, 2021 · 7 comments

Comments

@fryfrog
Copy link

fryfrog commented Dec 13, 2021

Describe the bug
Arch Linux just pushed Python 3.10 to everyone and now Bazarr does not run, complaining that AttributeError: module 'collections' has no attribute 'MutableMapping'.

To Reproduce
Try to run Bazarr on Python 3.10

Expected behavior
It should run! :)

Software (please complete the following information):

  • Bazarr: v1.0.1
  • OS: Arch Linux

Additional context
A similar issue for Tautulli, Tautulli/Tautulli#1558 which links to a few other issues. I didn't see any actual commits linked, so I'm not quite sure of the fix. Might just be importing collections.abc or something?

fryfrog@apollo ~  ❯ sudo -u bazarr /usr/bin/python /usr/lib/bazarr/bazarr.py --no-update --config /var/lib/bazarr
Bazarr starting...
Traceback (most recent call last):
  File "/usr/lib/bazarr/bazarr/main.py", line 18, in <module>
    from config import settings, url_sonarr, url_radarr, configure_proxy_func, base_url
  File "/usr/lib/bazarr/bazarr/config.py", line 9, in <module>
    from subliminal.cache import region
  File "/usr/lib/bazarr/bazarr/../libs/subliminal/__init__.py", line 12, in <module>
    from .core import (AsyncProviderPool, ProviderPool, check_video, download_best_subtitles, download_subtitles,
  File "/usr/lib/bazarr/bazarr/../libs/subliminal/core.py", line 29, in <module>
    from babelfish import Language, LanguageReverseError
  File "/usr/lib/bazarr/bazarr/../libs/babelfish/__init__.py", line 20, in <module>
    from .converters import (LanguageConverter, LanguageReverseConverter, LanguageEquivalenceConverter, CountryConverter,
  File "/usr/lib/bazarr/bazarr/../libs/babelfish/converters/__init__.py", line 6, in <module>
    from pkg_resources import iter_entry_points, EntryPoint
  File "/usr/lib/bazarr/bazarr/../libs/pkg_resources/__init__.py", line 82, in <module>
    __import__('pkg_resources.extern.packaging.requirements')
  File "/usr/lib/bazarr/bazarr/../libs/pkg_resources/_vendor/packaging/requirements.py", line 9, in <module>
    from pkg_resources.extern.pyparsing import stringStart, stringEnd, originalTextFor, ParseException
  File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 672, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 632, in _load_backward_compatible
  File "/usr/lib/bazarr/bazarr/../libs/pkg_resources/extern/__init__.py", line 43, in load_module
    __import__(extant)
  File "/usr/lib/bazarr/bazarr/../libs/pkg_resources/_vendor/pyparsing.py", line 943, in <module>
    collections.MutableMapping.register(ParseResults)
AttributeError: module 'collections' has no attribute 'MutableMapping'
Bazarr exited.
@poneli
Copy link

poneli commented Dec 13, 2021

Use the dev branch. I'm using Fedora 35 with Python 3.10.

@fryfrog
Copy link
Author

fryfrog commented Dec 13, 2021

@morpheus65535, sounds like it is already fixed, could you do a new release that includes the fix? :)

@morpheus65535
Copy link
Owner

Latest supported Python version is 3.8.x. Anything newer than that could work but there's no warranty. For now you may use the dev version that should work. There's no ETA for a merge to master branch to make this fix included in stable.

@fryfrog
Copy link
Author

fryfrog commented Dec 13, 2021

I'm not primarily asking for myself. I'm asking for all Arch users so the bazarr aur package will work again. At least it is already fixed, thanks for that! I'll think about pushing dev to this package if you think it'll be awhile.

@morpheus65535
Copy link
Owner

I should merge it within one or two weeks max.

@fryfrog
Copy link
Author

fryfrog commented Dec 13, 2021

Awesome! :)

@Kitt3120
Copy link

I should merge it within one or two weeks max.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants