# error: [Errno 13] Permission denied: '/usr/local/lib/python3.11/site-packages/mypkg-1.0.dist-info/METADATA'

- **ID:** `python/pip-egg-info-permission-denied`
- **Domain:** python
- **Category:** system_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

pip is installing into a system site-packages directory owned by root without sufficient privileges.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.x | active | — | — |

## Workarounds

1. **** (99% success)
   ```
   python3 -m venv .venv
source .venv/bin/activate
pip install mypkg
   ```
2. **** (90% success)
   ```
   python3 -m pip install --user mypkg
   ```

## Dead Ends

- **** — Installing as root pollutes the system Python and can break OS tooling; also may still fail on immutable dirs. (40% fail)
- **** — Weakens system security and can break other tools relying on permissions. (70% fail)
- **** — --user is ignored when running as root, so it still targets system site-packages. (85% fail)
