make pip ignore an existing wheel

Question:

If a .whl is available online, pip always installs it rather than compiling from source. However, for some specific module, the wheel happened to be compiled for the next processor generation and doesn’t run on a specific machine.

If I command it to just download the package, then it still downloads the wheel rather than source. Does pip have some mechanism to override this preference?

Asked By: ivan_pozdeev

||

Answers:

Try using

pip install <package> --no-binary :all:

You can find this option (and the values it takes) in pip install --help.

There’s also the --no-use-wheel option, but that has been deprecated in favour of the above and removed in pip 10.0.0.

Here is reference in official documentation:

https://pip.pypa.io/en/stable/reference/pip_install/#install-no-binary

Answered By: user707650
Categories: questions Tags: , ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.