Python error when attempting to install 'request' package using pip

后端 未结 2 638
小蘑菇
小蘑菇 2020-12-21 11:52

I\'m getting the below error message when attempting to install \'request\' Python package running command pip install request:

ERROR: Could

2条回答
  •  粉色の甜心
    2020-12-21 12:17

    From what I understood...

    There is a typo in the article. Where it says to install request it should actually say requests (plural, with an s at the end). The author of the screencast seems to make the same mistake, and I can only assume it is of no consequence to them, because they probably somehow had requests already installed beforehand in their Python environment.

    This can be confirmed by reading the actual code in the git repository linked in the article. In particular the following lines:

    import click
    import requests
    

    Update:

    It seems like (at some point in time at least) the request (without the s at the end) package contained some malware:

    • https://discuss.python.org/t/improving-risks-and-consequences-against-typosquatting-on-pypi/5090
    • I am trying to install setupfiles package from pip
    • https://quabr.com/48333990/what-is-the-story-behind-russianidiot-on-pypi

提交回复
热议问题