CPJKU / madmom

Python audio and music signal processing library
https://madmom.readthedocs.io
Other
1.35k stars 206 forks source link

Incompatible with Python 3.10 because MutableSequence was moved to collections.abc #502

Closed johentsch closed 2 years ago

johentsch commented 2 years ago

Expected behaviour

import madmom would be necessary to work in order to use this library.

Actual behaviour

Fails with ImportError: cannot import name 'MutableSequence' from 'collections' (..../python3.10/collections/__init__.py)

Steps needed to reproduce the behaviour

Import madmom under python 3.10

Suggested solution

Import MutableSequences from collections.abc

superbock commented 2 years ago

This was fixed in https://github.com/CPJKU/madmom/commit/45e9e7b756fa66cfbe3b1f96e142ee5ad6011ec8 already, will be included in v0.17 (to be released soon). So installing from source instead of using pip should solve the problem immediately.

inikishev commented 2 years ago

This was fixed in 45e9e7b already, will be included in v0.17 (to be released soon). So installing from source instead of using pip should solve the problem immediately.

when i try to install from source as it says i pasted "git clone --recursive https://github.com/CPJKU/madmom.git" and it said git command not found what do i do

inikishev commented 2 years ago

i pasted it into cmd btw wher epython works

frederikbrammer commented 1 year ago

You need to install git first, otherwise it won't work.

inikishev commented 1 year ago

You need to install git first, otherwise it won't work.

yeah thanks it didnt work when i installed git but i installed vscode and in its terminal it works

danigb commented 1 year ago

This was fixed in https://github.com/CPJKU/madmom/commit/45e9e7b756fa66cfbe3b1f96e142ee5ad6011ec8 already, will be included in v0.17 @superbock what is preventing this fix to be published?

superbock commented 1 year ago

The CI pipelines need to be updated. Most likely we should move to Github actions, PRs welcome ;)

davies-w commented 1 year ago

This is still an issue, over a year later? Can confirm that this works (ignore the extra flags) !pip install --upgrade --no-deps --force-reinstall --quiet 'git+https://github.com/CPJKU/madmom.git'

f0k commented 1 year ago

This is still an issue, over a year later?

Well, moving to Github actions will probably take 2-3 hours of fiddling if you haven't done that before, I can sympathize with @superbock.

If you don't have git available for some reason, you can also do: pip install --upgrade https://github.com/CPJKU/madmom/archive/master.zip

Or, to install a particular commit, do: pip install --force-reinstall --no-deps https://github.com/CPJKU/madmom/archive/45e9e7b756fa66cfbe3b1f96e142ee5ad6011ec8.zip

/edit: This will not work because it misses the madmom/models submodule. The result will be an installation of madmom that cannot be imported. Cloning the repository including submodules is the only working solution (https://madmom.readthedocs.io/en/latest/installation.html#install-from-source).