Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • funkwhale funkwhale
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 384
    • Issues 384
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 16
    • Merge requests 16
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • funkwhale
  • funkwhalefunkwhale
  • Issues
  • #1653

Closed
Open
Created Dec 28, 2021 by Baudouin Feildel@amdg2

Support Python 3.10

Steps to reproduce

Upgrade manual install of Funkwhale to 1.2.0-rc2 (should also apply to other versions) using Python 3.10 (e.g. on ArchLinux)

What happens?

When running python api/manage.py collectstatic --no-input the following error is reported:

2021-12-28 13:13:38,695 funkwhale_api.config INFO     Loaded env file at /srv/funkwhale/config/.env
2021-12-28 13:13:38,695 funkwhale_api.config INFO     Running with the following plugins enabled: funkwhale_api.contrib.scrobbler, funkwhale_api.contrib.listenbrainz, funkwhale_api.contrib.maloja
Traceback (most recent call last):
  File "/srv/funkwhale/api/manage.py", line 16, in <module>
    django.setup()
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/django/__init__.py", line 24, in setup
    apps.populate(settings.INSTALLED_APPS)
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/django/apps/registry.py", line 114, in populate
    app_config.import_models()
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/django/apps/config.py", line 301, in import_models
    self.models_module = import_module(models_module_name)
  File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
  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 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 "/srv/funkwhale/api/funkwhale_api/music/models.py", line 28, in <module>
    from funkwhale_api import musicbrainz
  File "/srv/funkwhale/api/funkwhale_api/musicbrainz/__init__.py", line 1, in <module>
    from .client import api
  File "/srv/funkwhale/api/funkwhale_api/musicbrainz/client.py", line 1, in <module>
    import memoize.djangocache
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/memoize/__init__.py", line 1, in <module>
    from .core import Memoizer
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/memoize/core.py", line 4, in <module>
    from .func import MemoizedFunction
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/memoize/func.py", line 9, in <module>
    from .options import OptionProperty
  File "/srv/funkwhale/virtualenv/lib/python3.10/site-packages/memoize/options.py", line 2, in <module>
    from collections import Callable
ImportError: cannot import name 'Callable' from 'collections' (/usr/lib/python3.10/collections/__init__.py)

N.B.: I had to manually remove the python-ldap dependency from requirements.txt to be able to install pip dependencies. But this is most probably unrelated.

What is expected?

No failure should happen

Context

Funkwhale version(s) affected: I was upgrading 1.1.4 to 1.2.0-rc2 (I would upgrade to 1.2.0, but the build artifacts are not available at the expected URLs)

OS: ArchLinux

Installation type: manual install

Edited Jan 13, 2022 by Georg Krause
Assignee
Assign to
Time tracking