Pip-Pit-Sammlung

1. pip: Das Element „pip“ kann nicht als Name eines Cmdlets, einer Funktion, einer Skriptdatei oder eines ausführbaren Programms erkannt werden. Bitte überprüfen Sie die Schreibweise des Namens. Falls ein Pfad enthalten ist, stellen Sie sicher, dass der Pfad korrekt ist, und versuchen Sie es erneut.

Lösung:
Fügen Sie den Pfad zum Python-sciprt-Ordner im Pfad der Umgebungsvariablen hinzu
Fügen Sie hier eine Bildbeschreibung ein

2、pip._vendor.urllib3.Exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Zeitüberschreitung beim Lesen

Ursache des Problems: Beim Download tritt eine Zeitüberschreitung auf. Fügen Sie einfach die Zeitüberschreitung während der Installation hinzu.

解决方案:pip --default-timeout=1000 install -U 模块

3. Problemlösungsfehler: Pakete konnten aufgrund eines Betriebssystemfehlers nicht installiert werden: [WinError 2] Das System kann die angegebene Datei nicht finden.

cmd中输入:
python -m pip install --upgrade pip

4、FEHLER: Es konnte keine Version gefunden werden, die die Anforderungen von pymysql erfüllt (aus den Versionen: keine). FEHLER

Grund: Das Netzwerk ist instabil. Ersetzen Sie es einfach durch ein inländisches Image und installieren Sie es, dann ist alles in Ordnung.

具体报错:
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/pymysql/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/pymysql/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/pymysql/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/pymysql/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/pymysql/
ERROR: Could not find a version that satisfies the requirement pymysql (from versions: none)
ERROR: No matching distribution found for pymysql
WARNING: You are using pip version 21.3.1; however, version 23.0.1 is available.
You should consider upgrading via the 'D:\workplace\API_autoTest\api_lemon48_demo\venv\Scripts\python.exe -m pip install --upgrade pip' command.

lösen:

pip install pymysql -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com```

Treten Sie weiterhin auf Fallstricke und denken Sie jedes Mal daran, wenn Sie darauf treten~

Supongo que te gusta

Origin blog.csdn.net/TDLDDMZ/article/details/127561283
Recomendado
Clasificación