# error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.

- **ID:** `python/pip-subprocess-exited-with-error`
- **Domain:** python
- **Category:** install_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

A package's build backend (legacy setuptools setup.py) crashed during wheel creation, usually due to missing system C headers, an incompatible setuptools version, or a Cython/compiler failure.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.8 | active | — | — |
| 3.9 | active | — | — |
| 3.10 | active | — | — |
| 3.11 | active | — | — |
| 3.12 | active | — | — |

## Workarounds

1. **** (85% success)
   ```
   Install the needed system build tools first. On Debian/Ubuntu: `sudo apt-get install build-essential python3-dev libffi-dev libssl-dev`. On macOS: `xcode-select --install`. Then retry `pip install <pkg>`.
   ```
2. **** (80% success)
   ```
   Prefer a prebuilt wheel: `pip install --only-binary=:all: <pkg>`, or upgrade the build toolchain with `pip install --upgrade pip setuptools wheel` before installing.
   ```
3. **** (75% success)
   ```
   Read the full traceback above the error (pip truncates it). Re-run with `pip install -v <pkg>` to see the actual compiler error and address that specific missing dependency.
   ```

## Dead Ends

- **** — The build fails deterministically; retrying does not supply the missing compiler or headers. (95% fail)
- **** — Disabling isolation makes pip use the current environment's setuptools, which may be even older and fail the same way. (70% fail)
- **** — Older pip still invokes the same broken build backend and loses modern resolver features. (60% fail)
