gpt4 book ai didi

python - 从 PIP 安装包时,它使用私有(private)存储库/服务器

转载 作者:太空宇宙 更新时间:2023-11-03 21:18:45 25 4
gpt4 key购买 nike

当我使用 pip 安装软件包时,它是从我的私有(private)仓库而不是公共(public)/官方仓库安装的...如何修复它?

编辑:

(test)  mymac@pc137  ~/workspace  pip install pacman

收集 pacman

User for devpi.packageserver.com:

貌似devpi已经被pip使用了...如何关闭devpi?我不想在使用 pip 安装软件包时使用它...

最佳答案

额外的服务器使用可以保留在配置文件pip.conf(或 Windows 上的pip.ini)中。既然您声明您使用的是 MacOS,那么您似乎已经找到了正确的位置(根据 official docs ):

The names and locations of the configuration files vary slightly across platforms. You may have per-user, per-virtualenv or site-wide (shared amongst all users) configuration:

Per-user:

...

On macOS the configuration file is $HOME/Library/Application Support/pip/pip.conf if directory $HOME/Library/Application Support/pip exists else $HOME/.config/pip/pip.conf.

There are also a legacy per-user configuration file which is also respected, these are located at:

On Unix and macOS the configuration file is: $HOME/.pip/pip.conf

找到配置文件,使用编辑器打开它,然后注释掉(或删除)设置 index-url/extra-index-url 选项的行。

关于python - 从 PIP 安装包时,它使用私有(private)存储库/服务器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54483692/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com