python-bluezero: Version 0.9.0 cannot be installed via pip

Hello,

The build system for my project, which depends on bluezero, started failing back in May when version 0.9.0 was released. The issue seems related to the new dependencies that were added, which cannot be installed on Linux systems for some reason.

To resolve the issue, I’ve had to pin to version 0.8.0.

The following is the error log from the build, which runs on Github actions, and I was able to reproduce locally in a clean Python 3.12 virtual environment by running pip install bluezero.

Collecting PyGObject (from bluezero)
  Using cached pygobject-3.48.2.tar.gz (715 kB)
  Installing build dependencies: started
  Installing build dependencies: finished with status 'error'
  error: subprocess-exited-with-error
  
  × pip subprocess to install build dependencies did not run successfully.
  │ exit code: 1
  ╰─> [52 lines of output]
      Collecting meson-python>=0.12.1
        Using cached meson_python-0.16.0-py3-none-any.whl.metadata (4.1 kB)

...
 -- abbreviated --
...
            Package cairo was not found in the pkg-config search path.
            Perhaps you should add the directory containing `cairo.pc'
            to the PKG_CONFIG_PATH environment variable
            No package 'cairo' found
            Command '['pkg-config', '--print-errors', '--exists', 'cairo >= 1.15.10']' returned non-zero exit status 1.
            [end of output]
      
        note: This error originates from a subprocess, and is likely not a problem with pip.
        ERROR: Failed building wheel for pycairo
      Failed to build pycairo
      ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (pycairo)
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
Error: Process completed with exit code 1.

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Comments: 18 (12 by maintainers)

Most upvoted comments

Hi @WayneKeenan ,

I think explicitly adding PyGObject brings in 1 or more dependancies that would sometimes not be available in a venv, but it’s been a while so please don’t quote me.

I believe that the PyGObject project has done some work to make things more pip friendly these days and that is why I added the dependency. However, testing on different systems and different OSes is difficult for me. I’m hoping the more eyes we can get on this the more robust this will become over time 🤞