Skip to content

BUG: PyMC installation fails on macOS (arm64, Homebrew Python 3.14) due to NumPy and Pytensor build incompatibility #7934

@fcotizelati

Description

@fcotizelati

Describe the issue:

Attempting to install PyMC on macOS (M3, arm64) using Homebrew Python 3.14 fails during dependency resolution/build. pytensor tries to build against numpy<1.26, which has no pre-built wheels for Python 3.14, causing pip to backtrack indefinitely and then fail with:

pip._vendor.pyproject_hooks._impl.BackendUnavailable: Cannot import 'setuptools.build_meta'

Reproduceable code example:

# Create a clean environment
python3.14 -m venv pymc_test_env
source pymc_test_env/bin/activate

# Upgrade pip and attempt installation
pip install -U pip setuptools wheel
pip install pymc

Error message:

Collecting pymc
  Using cached pymc-5.26.1-py3-none-any.whl
...
ERROR: subprocess-exited-with-error
pip._vendor.pyproject_hooks._impl.BackendUnavailable: Cannot import 'setuptools.build_meta'

PyMC version information:

PyMC/PyMC3 Version: attempted installation of pymc==5.26.1 (installation failed)

PyTensor/Aesara Version: not installed (build failed for pytensor==2.17.1)

Python Version: 3.14.0 (Homebrew build, arm64)

Context for the issue:

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions