Home >Database >Mysql Tutorial >How Do I Install a Specific Version of a Python Package Using pip?
Installing a Specific Package Version with Python's pip
Problem:
When attempting to install a specific version of a package (in this case, MySQL_python 1.2.2) using pip, the latest version (1.2.3) is installed despite using the == syntax.
Answer:
To install a specific package version, you can use the following options:
Using --force-reinstall (Recommended):
TL;DR:
pip install --force-reinstall -v "MySQL_python==1.2.2"
Details:
Using -I --ignore-installed:
TL;DR:
pip install -Iv "MySQL_python==1.2.2"
Details:
Additional Notes:
The above is the detailed content of How Do I Install a Specific Version of a Python Package Using pip?. For more information, please follow other related articles on the PHP Chinese website!