Python PyCharm 加载包列表时出错

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/39498602/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-19 22:19:46  来源:igfitidea点击:

PyCharm Error Loading Package List

pythonpycharmpypi

提问by geoffrey007

I just downloaded PyCharm the other day and wanted to download a few packages. I'm using Windows 10 with PyCharm 2016.2.2 and python 3.5.2. When I go to the available packages screen it continually states:

前几天刚下载了PyCharm,想下载几个包。我将 Windows 10 与 PyCharm 2016.2.2 和 python 3.5.2 一起使用。当我转到可用包屏幕时,它不断指出:

Error loading package list:pypi.python.org

加载包列表时出错:pypi.python.org

I was just trying to download BeautifulSoup and I'm clearly missing something. Any help would be wonderful.

我只是想下载 BeautifulSoup,但我显然错过了一些东西。任何帮助都会很棒。

回答by Chris Broski

I am behind a corporate firewall and had this problem. All I had to do was go to Settings/Appearance and Behavior/System Settings/HTTP Proxyand check Auto-detect proxy settingsand it worked.

我在公司防火墙后面,遇到了这个问题。我所要做的就是去Settings/Appearance and Behavior/System Settings/HTTP Proxy检查一下Auto-detect proxy settings,它奏效了。

回答by Nick PV

I got the same problem and solution was that I got some other repositories added to repositories manager. So, make sure that you don't have anything extra then

我遇到了同样的问题,解决方案是我将其他一些存储库添加到存储库管理器中。所以,确保你没有任何额外的东西

https://pypi.python.org/simpleat Repositories

https://pypi.python.org/simple位于存储库

enter image description hereenter image description here

在此处输入图片说明在此处输入图片说明

回答by Hitesh Sahu

Update PyCharm January 2020 Build

更新 PyCharm 2020 年 1 月构建

If you are behind a proxy then

如果你在代理后面,那么

  • Go to File->Settingssearch for proxy in the settings dialog
  • Check Auto-Detect Proxy Settings:
  • 在设置对话框中转到文件-> 设置搜索代理
  • 检查自动检测代理设置

enter image description here

在此处输入图片说明

回答by u8392312

First of all, I think you should use Default Preferences in File to install packages. Second, you should check "Manage Repositories" if there's any unavailable source.

首先,我认为您应该使用文件中的默认首选项来安装软件包。其次,如果有任何不可用的源,您应该检查“管理存储库”。

回答by pk786

All the above solution did not work for me, I had to manually install the package using proxy:

以上所有解决方案对我都不起作用,我不得不使用代理手动安装包:

pip install -U <package_name> --user --proxy=<your proxy>

回答by Giorgos Myrianthous

If you are running PyCharm on OSX behind a proxy you need to define proxy configuration the following should do the trick:

如果您在代理后面的 OSX 上运行 PyCharm,您需要定义代理配置,以下内容应该可以解决问题:

  • Click on PyCharm > Preferences > Appearance and Behavior > System Settings -> HTTP Proxy
  • Either select Auto-detect proxy settings
  • Or select Manual proxy configuration
    1. Define the Host Nameand Port
    2. and optionally Proxy Authenticationif required
  • Click Apply
  • 点击PyCharm > Preferences > Appearance and Behavior > System Settings -> HTTP Proxy
  • 选择自动检测代理设置
  • 或者选择手动代理配置
    1. 定义主机名端口
    2. 如果需要,还可以选择代理身份验证
  • 点击应用

回答by ode2k

You should update to PyCharm 2016.2.3

你应该更新到 PyCharm 2016.2.3

Help -> Check for Updates...

Help -> Check for Updates...