简体   繁体   中英

not able to create conda environment

There is an error message when i try to create an environment. I have installed Anaconda3 and it is with python3.7 and i have set the environment variable on my window10 machine. With the use of jupyter notebook i do my works on machine learning. But i am not be able to import tensorflow library on it. So I tried to install an environment. on my cmd i tried

conda create -n tfp3.6 python=3.6
C:\>conda create -n tfp3.6 python=3.6
Solving environment: failed

CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://repo.anaconda.com/pkgs/main/noarch/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/main/noarch/repodata.json.bz2 (Caused by SSLError("Can\'t connect to HTTPS URL because the SSL module is not available."))'))

And this is my environment variables this is my environment variables

please help. Thanks inadvance

This is very likely to be a case of Python3.7 issue on some Windows systems.

The root of problem hide in tail of error-message: "SSLError("Can\\'t connect to HTTPS URL because the SSL module is not available.")"

This issue occur for Python3.7 running on some Windows (I suffered it on Windows 10). The solution is: install and use Python3.6

PS: In my case, I found the very tricky exhibition of this problem: code successfully run under conda-shell, successfully run under Jupyter-notebook, but fails to run from cmd with python.exe taken from either conda installation or conda-created environment.

To be sure you suffer the same problem, you may run this line in cmd:

python -c "import requests; response = requests.get(' https://stackoverflow.ru ', cert=False); print(response);"

(suppose requests package is installed, for instance via cmd execution: "pip install requests")

This cmd execution should success to run under anaconda-shell, but fails to run under python3.7

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM