cibuildwheel icon indicating copy to clipboard operation
cibuildwheel copied to clipboard

Compatibility with Pixi package manager

Open SeaOtocinclus opened this issue 1 year ago • 1 comments

Description

I would love to use pixi package manager to manage the environment used by cibuildwheel such that:

  • Python requirements would be installed and managed by pixi
  • CIBW_BEFORE_BUILD could be system independent call to install conda library

As today (on Mac), when I create a pixi environment with python and try to launch cibuildwheel in it, cibuildwheel complains that CPython does not exists, since it is looking for a system wide, and not an environment one.

aka. on mac

% python --version
Python 3.11.7

% python3 -m cibuildwheel --output-dir dist --platform macos --config-file {package}/pyproject_arm64.toml --archs arm64 .

Here we go!

Building cp311-macosx_arm64 wheel
CPython 3.11 macOS arm64 - Apple Silicon
Installing Python cp311...
+ pkgutil --pkgs   ✕ 0.16s
Error: Error: CPython 3.11 is not installed.
cibuildwheel will not perform system-wide installs when running outside of CI.

Any suggestion from the community on how to use PIXI or conda package with cibuildwheel to ease 3rd party library install and python package versions?

Build log

No response

CI config

No response

SeaOtocinclus avatar Aug 01 '24 21:08 SeaOtocinclus

Pixi uses conda, which has its own build stack. It's not compatible with PyPI. You can't use them to build highly compatible wheels, just like you can't use homebrew's Python or other libraries. Cibuildwheel is specifically looking for the official installers, which are compiled with macOS 10.9+ (10.13+ for CPython 3.13+) in mind.

henryiii avatar Aug 09 '24 16:08 henryiii