I'm trying to configure my requirements.txt
which is the following:
wheel
apache-airflow
I created python3.8 -m venv ~/test-env
and tried to do the installation. The problem is
python -m pip install -r requirements.txt
produces tons of messages
error: invalid command 'bdist_wheel'
----------------------------------------
Failed building wheel for thrift
I made sure that wheel
is installed when doing requirements.txt
installation:
Collecting wheel (from -r requirements.txt (line 1))
Using cached https://files.pythonhosted.org/packages/00/83/b4a77d044e78ad1a45610eb88f745be2fd2c6d658f9798a15e384b7d57c9/wheel-0.33.6-py2.py3-none-any.
But if I install it separately
python -m pip install wheel
python -m pip install -r requirements
it works fine and the python -m pip -r requirements
finishes with no error messages.
So isn't it possible to put wheel
installation into requirements.txt
? What is the proper way to deal with it when installing into venv
? To install it before requirements.txt
installation?
I believe this happens with older versions of pip. For example in my quick tests it happens with pip 9.0.1 which is delivered by default with Python 3.6's ensurepip standard library, but doesn't happen once pip is updated to 19.2.3 which as far as I know should be bundled with Python 3.8. You seem to be using Python 3.8 so I'm confused by the fact that you encounter this error. Anyway this error, shouldn't effectively block the actual installation of the requirements.
If possible I'd recommend updating pip:
python -m pip install --upgrade pip
before installing the requirements:
python -m pip install --requirement requirements.txt
Installing wheel (or updating pip) from within the requirements file is not useful in this case.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With