-
Notifications
You must be signed in to change notification settings - Fork 74.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mac + Python 3.6.1: Attempting to download mnist data results in CERTIFICATE_VERIFY_FAILED error #10779
Comments
Could you try with python2 (default system install of py)? Also, how did you install with brew or macports (we use brew for our testing so that's more likely to work). |
I installed Python 3.6 using the dmg installer from the Python website (not through brew or macports). It seems to work with Python 2.7.10. I had thought that in Python 2.x urlretrieve didn't validate the server certificate, but apparently it does as of 2.7.9: https://docs.python.org/2/library/urllib.html |
It works me on python 3.4 on Linux. I'd try installing python3.6 using brew. It could be the python3 distrib you are using has out of data certificates. |
This might have also been because I recently switched to a new machine and it's still only partially installed :) For future reference: if you want to use the Python dmg installer, you also have to read Python 3's ReadMe and run the Thanks for the quick response, @aselle! |
If you want to just copy paste into Terminal: |
I'm getting exactly this same issue on MacOSX 10.11.6 I first followed exactly the steps here for the Then, following the first 2 steps in this tutorial https://www.tensorflow.org/get_started/mnist/beginners I see the following; any suggestions for working-around this (e.g. could I download this from somewhere else?) would be greatly appreciated.
|
@brightbytes-dude Did you run the command listed here: #10779 (comment)
|
That did the trick, thanks!! (I stupidly assumed that was only relevant for the |
Could you please change the MNIST download URL in contrib/learn/python/learn/datasets/mnist.py to not use https ? That will help people who are having this problem. In tried in a browser and the http download link works. line to change: |
Hello,
During handling of the above exception, another exception occurred: Traceback (most recent call last): The main difference is that I'm on WINDOWS 10 and I cannot find the certificates command. |
I have same problem with ssl and this line fix it, |
If there's anyone stumbling across this page but looking for the answer to permit Tensorflow Hub in Ubuntu, I made it work like this:
On top of this, some magical combination of configuration of my corporate proxy, restarting the Jupyter notebook kernel, and running TF Hub from a script on the terminal rather than from a notebook eventually caused TF Hub to work both on the terminal and in the notebook. |
running that command also failed. |
on MacOS |
|
What is the solution for those using a virtual environment? Update: It looks like running that same system command pointed out above 👆 does the trick when in an active venv as well. Good to know! |
thank u! |
Thanks! It worked! :D |
Thanks |
I see both the urls are same. |
It worked for me. |
We only need input at the Terminal |
change 'https://...' to 'http://...' |
/Applications/Python 3.7/Install Certificates.command |
How to do it in Manjaro Linux? I have Python3.7 tensorflow. |
Thanks man! It works for me! |
Incase of linux...go to .local/python3.X/lib/python3.6/site-packages/keras/utils/data_utils.py and below import statements add these----
|
You saved my life with this comment! <3 |
This works for me on ubuntu New Line |
Here's what worked for me:
That's all. The keras download utility looks in that folder for cached data before going over the network. (Python 3.7.3, tensorflow 2.1.0) |
/Applications/Python\ 3.6/Install\ Certificates.command does this work for virtual environment as well? |
System information
This doesn't reproduce with TensorFlow 1.1.
The text was updated successfully, but these errors were encountered: