TL;DR: The MySQL driver is not installed. Run python -m pip install mysql-connector-python (the maintained package; the old mysql-connector is abandoned).

```text
ModuleNotFoundError: No module named 'mysql'
```

## Fix it

1. Install the right package: python -m pip install mysql-connector-python. Expected: Successfully installed.
2. If the ancient mysql-connector is installed, remove it first: pip uninstall mysql-connector. Expected: gone.
3. Verify: python -c "import mysql.connector; print(mysql.connector.__version__)". Expected: a version.
4. Add mysql-connector-python to requirements.txt.

## When this applies
- import mysql.connector fails with ModuleNotFoundError.

## When it doesn't
- The import works but connect() fails: connection/auth problem, different skills.
- You use PyMySQL or mysqlclient: those are different drivers with their own installs.

## Compatibility
- mysql-connector-python 8.x; Python 3.8+.

## Why it happens
Two similarly named packages exist (mysql-connector abandoned, mysql-connector-python maintained). Tutorials mix them up, and fresh envs have neither.

## Edge cases
- Some distros ship python3-mysql.connector via apt; pip is still the safer route in venvs.
