# ERROR: Package 'X' has no 'pyproject.toml' or 'setup.py'

- **ID:** `pip/package-has-no-pyproject-toml-or-setup-py`
- **Domain:** pip
- **Category:** install_error
- **Error Code:** `ERROR`
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The package is either not a valid Python package, the index URL is wrong, or the package name is misspelled, causing pip to fail to find any build metadata.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| pip 21.3+ | active | — | — |
| Python 3.7-3.12 | active | — | — |

## Workarounds

1. **pip install --no-index --find-links=/path/to/wheels <package>** (70% success)
   ```
   pip install --no-index --find-links=/path/to/wheels <package>
   ```
2. **pip install <package>==<exact_version> --only-binary=:all:** (75% success)
   ```
   pip install <package>==<exact_version> --only-binary=:all:
   ```
3. **pip install <package> -i https://pypi.org/simple/ --trusted-host pypi.org** (85% success)
   ```
   pip install <package> -i https://pypi.org/simple/ --trusted-host pypi.org
   ```

## Dead Ends

- **Installing the package with --no-build-isolation flag** — The flag only disables build isolation; if the package has no build files at all, this still fails. (95% fail)
- **Upgrading pip to the latest version** — The error is about missing package metadata, not pip's resolver or version compatibility. (90% fail)
- **Running pip install with --verbose to get more details** — Verbose output does not provide missing build files; the root cause remains the same. (85% fail)
