NF91
NF91

Reputation: 41

Error launching Jupyter Notebook: ssl.SSLError: [ASN1] nested asn1 error

I installed Anaconda yesterday and when I tried to launch Jupiter Notebook, it opens for a second and closes. I read there are some issues with the shortcut, but I couldn't find a solution that works for me. Here's the error message I get when I try to launch it:

Traceback (most recent call last):
File "C:\Users\nikol\anaconda3\Scripts\jupyter-notebook-script.py", line 6, in 
from notebook.notebookapp import main
File "C:\Users\nikol\anaconda3\lib\site-packages\notebook\notebookapp.py", line 64, in 
from tornado import httpserver
File "C:\Users\nikol\anaconda3\lib\site-packages\tornado\httpserver.py", line 32, in 
from tornado.http1connection import HTTP1ServerConnection, HTTP1ConnectionParameters
File "C:\Users\nikol\anaconda3\lib\site-packages\tornado\http1connection.py", line 34, in 
from tornado import iostream
File "C:\Users\nikol\anaconda3\lib\site-packages\tornado\iostream.py", line 40, in 
from tornado.netutil import ssl_wrap_socket, _client_ssl_defaults, _server_ssl_defaults
File "C:\Users\nikol\anaconda3\lib\site-packages\tornado\netutil.py", line 39, in 
_client_ssl_defaults = ssl.create_default_context(ssl.Purpose.SERVER_AUTH)
File "C:\Users\nikol\anaconda3\lib\ssl.py", line 750, in create_default_context
context.load_default_certs(purpose)
File "C:\Users\nikol\anaconda3\lib\ssl.py", line 574, in load_default_certs
self._load_windows_store_certs(storename, purpose)
File "C:\Users\nikol\anaconda3\lib\ssl.py", line 566, in _load_windows_store_certs
self.load_verify_locations(cadata=certs)
ssl.SSLError: [ASN1] nested asn1 error (_ssl.c:4114)

What seems to be the issue?

Upvotes: 4

Views: 3474

Answers (1)

Christopher Peisert
Christopher Peisert

Reputation: 24134

In the file "C:\Users\USERNAME\anaconda3\lib\ssl.py", try removing the two lines (at approximately line 470) starting with:

if certs: self.load_verify_locations(cadata=certs)

See Jupyter Notebook issue #4245, Problem to launch jupyter notebook.

Upvotes: 4

Related Questions