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

Unresolved Modules with version 2.1.0 #5511

Open
gboysko opened this issue Nov 22, 2024 · 10 comments
Open

Unresolved Modules with version 2.1.0 #5511

gboysko opened this issue Nov 22, 2024 · 10 comments

Comments

@gboysko
Copy link

gboysko commented Nov 22, 2024

Unresolved modules with version 2.1.0

Running this command in verbose (-vv) mode:

 beet -vv
user configuration: /home/glenn/.config/beets/config.yaml
data directory: /home/glenn/.config/beets
plugin paths: 
** error loading plugin embedart:
Traceback (most recent call last):
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beets/plugins.py", line 268, in load_plugins
    namespace = __import__(modname, None, None)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beetsplug/embedart.py", line 21, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'

** error loading plugin fetchart:
Traceback (most recent call last):
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beets/plugins.py", line 268, in load_plugins
    namespace = __import__(modname, None, None)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beetsplug/fetchart.py", line 23, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'

** error loading plugin lastgenre:
Traceback (most recent call last):
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beets/plugins.py", line 268, in load_plugins
    namespace = __import__(modname, None, None)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/glenn/.local/share/pipx/venvs/beets/lib/python3.12/site-packages/beetsplug/lastgenre/__init__.py", line 29, in <module>
    import pylast
ModuleNotFoundError: No module named 'pylast'

error: replaygain initialization failed: Failed to load GStreamer: python-gi not found

Led to this problem:

$ pipx uninstall beets
$ pipx install beets

Setup

  • OS: Ubuntu 24.10
  • Python version: 3.12.7
  • beets version: 2.1.0
  • Turning off plugins made problem go away (yes/no): no
@snejus
Copy link
Member

snejus commented Nov 22, 2024

It seems like you have plugins embedart, fetchart, lastgenre and replaygain enabled, however their dependencies are missing. Have you installed beets with extras for each of those plugins? For example see fetchart docs.

In your case the command is probably pipx install beets[embedart,fetchart,pylast,replaygain]

@gboysko
Copy link
Author

gboysko commented Nov 22, 2024

Thanks, @snejus. I had not installed those plugins. I was following the FAQ's instructions on installation, but didn't notice that. I uninstalled, then installed again using this command:

$ pipx install beets beets[embedart,fetchart,pylast,replaygain] --force
Installing to existing venv 'beets'
  installed package beets 2.1.0, installed using Python 3.12.7
  These apps are now globally available
    - beet
done! ✨ 🌟 ✨
Installing to existing venv 'beets'
Fatal error from pip prevented installation. Full pip output in file:
    /home/glenn/.local/state/pipx/log/cmd_2024-11-22_15.01.37_pip_errors.log

pip seemed to fail to build package:
    PyGObject

Some possibly relevant errors from pip install:
    error: subprocess-exited-with-error
    ../meson.build:1:0: ERROR: Compiler cc cannot compile programs.
    error: metadata-generation-failed

⚠️  Not removing existing venv /home/glenn/.local/share/pipx/venvs/beets
    because it was not created in this session
Error installing beets from spec 'beets[embedart,fetchart,pylast,replaygain]'.

Not sure how to resolve PyGObject.

@snejus
Copy link
Member

snejus commented Nov 23, 2024

See replaygain docs.

It seems like GStreamer is missing from your system. Have you been using replaygain previously or did you only enable it now? If your current configuration was in place before the update, I expected system dependencies to be present already!

@gboysko
Copy link
Author

gboysko commented Nov 23, 2024

I had used replaygain previously. I'm not sure how it was lost. I will try to resolve all of the various dependencies. Even after installing python3-gi, I'm still unable to install due to an unresolved dependency of PyGObject. I'll keep digging...

@snejus
Copy link
Member

snejus commented Nov 26, 2024

What sort of system are you using? It seems like system dependencies are missing, for example on Ubuntu you'd want to install

sudo apt update
sudo apt install ffmpeg gobject-introspection libgirepository1.0-dev

@gboysko
Copy link
Author

gboysko commented Nov 26, 2024 via email

@gboysko
Copy link
Author

gboysko commented Nov 26, 2024

Sorry no luck, even after installing dependencies.

$ sudo apt update
[OUTPUT omitted--all success]

$ sudo apt install ffmpeg gobject-introspection libgirepository1.0-dev
ffmpeg is already the newest version (7:7.0.2-3ubuntu1).
ffmpeg set to manually installed.
gobject-introspection is already the newest version (1.80.1-4).
gobject-introspection set to manually installed.
libgirepository1.0-dev is already the newest version (1.80.1-4).
Summary:
  Upgrading: 0, Installing: 0, Removing: 0, Not Upgrading: 27

$ pipx install beets[embedart,fetchart,lastgenre,scrub,replaygain] --force
Fatal error from pip prevented installation. Full pip output in file:
    /home/glenn/.local/state/pipx/log/cmd_2024-11-26_15.41.03_pip_errors.log

pip seemed to fail to build package:
    PyGObject

Some possibly relevant errors from pip install:
    error: subprocess-exited-with-error
    ../meson.build:1:0: ERROR: Compiler cc cannot compile programs.
    error: metadata-generation-failed

Error installing beets from spec 'beets[embedart,fetchart,lastgenre,replaygain,scrub]'.

Not sure what else I can do. I was able to use the prior version of beets, fwiw.

@gboysko
Copy link
Author

gboysko commented Nov 26, 2024

I'm including the error log file.

cmd_2024-11-26_15.41.03_pip_errors.log

The file indicates failures to compile?

@snejus
Copy link
Member

snejus commented Nov 28, 2024

Is replaygain working fine with the old version? Could you run pipx runpip beets list and show me the list of packages installed in this environment?

@snejus
Copy link
Member

snejus commented Nov 28, 2024

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

2 participants