Django MySQLdb and MySQLClient Install Failure

Environment: MacBook Pro M1 MAX 16 Inch 2021

macOS Monterey Version 12.5 Just Updated - There was a bug in 12.4

MySQL Downloaded and Installed and running. Access by MySQL Workbench Works.

Initial Database created for Django Project.

Activity :** Tried to install mysqlclient within virtual environment using pipenv install mysqlclient

Error Message:

pipenv install mysqlclient
Courtesy Notice: Pipenv found itself running within a virtual environment, so it will automatically use that environment, instead of creating its own for any project. You can set PIPENV_IGNORE_VIRTUALENVS=1 to force pipenv to ignore that environment and create its own instead. You can set PIPENV_VERBOSITY=-1 to suppress this warning.
Installing mysqlclient…
Error: An error occurred while installing mysqlclient!
Error text: Collecting mysqlclient
Using cached mysqlclient-2.1.1.tar.gz (88 kB)
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status ‘error’

error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [16 lines of output]
/bin/sh: mysql_config: command not found
/bin/sh: mariadb_config: command not found
/bin/sh: mysql_config: command not found
Traceback (most recent call last):
File “”, line 2, in
File “”, line 34, in
File “/private/var/folders/67/g6ljn0wn3gd2hz1n0_9p0dtc0000gn/T/pip-install-eutd_d2a/mysqlclient_9d27b524b01b4c1bbd7856b93025a749/setup.py”, line 15, in
metadata, options = get_config()
File “/private/var/folders/67/g6ljn0wn3gd2hz1n0_9p0dtc0000gn/T/pip-install-eutd_d2a/mysqlclient_9d27b524b01b4c1bbd7856b93025a749/setup_posix.py”, line 70, in get_config
libs = mysql_config(“libs”)
File “/private/var/folders/67/g6ljn0wn3gd2hz1n0_9p0dtc0000gn/T/pip-install-eutd_d2a/mysqlclient_9d27b524b01b4c1bbd7856b93025a749/setup_posix.py”, line 31, in mysql_config
raise OSError(“{} not found”.format(_mysql_config_path))
OSError: mysql_config not found
mysql_config --version
mariadb_config --version
mysql_config --libs
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

This is likely caused by a bug in mysqlclient. Report this to its maintainers.
✘ Installation Failed

Tried Stackoverflow