SSL Error while installing any package from conda prompt

给你一囗甜甜゛ 提交于 2020-03-19 07:52:17

问题


I use Anaconda Navigator for my machine learning experiments. Recently, I have started getting this strange SSL error no matter what I try to install using conda prompt. The error is SSL error. I am posting the error message that I get

Solving environment: failed

CondaHTTPError: HTTP 000 CONNECTION FAILED for url https://repo.anaconda.com/pkgs/free/linux-64/repodata.json.bz2 Elapsed: -

An HTTP error occurred when trying to retrieve this URL. HTTP errors are often intermittent, and a simple retry will get you on your way.

If your current network has https://www.anaconda.com blocked, please file a support request with your network engineering team.

SSLError(MaxRetryError('HTTPSConnectionPool(host=\'repo.anaconda.com\', port=443): Max retries exceeded with url: /pkgs/free/linux-64/repodata.json.bz2 (Caused by SSLError(SSLError("bad handshake: Error([(\'SSL routines\', \'ssl3_get_server_certificate\', \'certificate verify failed\')],)",),))',),)

I have an institutional proxy server; the credentials, apt.conf file etc are all OK.

Even then I am not able to install any package using conda.

Interestingly, I have installed numerous packages using conda prompt and I never faced any such error until recently. Also, I am able to follow the links (using the browser) given in the error message which means that the proxy is not blocking the site.

I was asked to use

conda config --set ssl_verify True

but even this did not help. Any help ?

I even entered the proxy server details as given in HTTP error while using conda for installation of any packages


回答1:


Try copying these files from Anaconda3/Library/bin to Anaconda3/DLLs :

libcrypto-1_1-x64.dll

libssl-1_1-x64.dll




回答2:


When I had an SSL error related to conda on my work laptop behind a firewall, I had to set ssl_verify to false to get it to work.




回答3:


The following steps worked for me :

Use this command to see proxy_servers

1)conda config --show

This will remove saved proxy servers from anaconda configuration.

2)conda config --remove-key proxy_servers

3)conda clean --source-cache

Hope this helps you..



来源:https://stackoverflow.com/questions/51892938/ssl-error-while-installing-any-package-from-conda-prompt

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!