Python 3 - WinError 87 when installing new modules

Viewed 1924

I'm trying to install new modules in python 3 and when I run python -m pip install filename on my win10 machine then I'm getting:

Using cached https://files.pythonhosted.org/packages/8a/48/a76be51647d0eb9f10e2a4511bf3ffb8cc1e6b14e9e4fab46173aa79f981/termcolor-1.1.0.tar.gz
    Error [WinError 87] The parameter is incorrect while executing command python setup.py egg_info
Could not install packages due to an EnvironmentError: [WinError 87] The parameter is incorrect

I tried to run PowerShell as an admin but the problem persists. I also tried to run this command in the cmd.

2 Answers

I received the same error message when executing a pip install numwords2 from the Pycharm console.

I then upgraded pip, using:

python -m pip install --upgrade pip

which uninstalled pip-19.1.1 and replaced it with pip-19.3.1.

The next whack at pip install worked well.

Related