question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Spyder 5.0.4 crashes with proxy error to kite.com

See original GitHub issue

Issue Report Checklist

  • [ x] Searched the issues page for similar reports
  • Read the relevant sections of the Spyder Troubleshooting Guide and followed its advice
  • [ x] Reproduced the issue after updating with conda update spyder (or pip, if not using Anaconda)
  • Could not reproduce inside jupyter qtconsole (if console-related)
  • Tried basic troubleshooting (if a bug/error)
    • [ x] Restarted Spyder
    • [ x] Reset preferences with spyder --reset
    • Reinstalled the latest version of Anaconda
    • Tried the other applicable steps from the Troubleshooting Guide
  • [x ] Completed the Problem Description, Steps to Reproduce and Version sections below

Problem Description

Spyder 5.0.4 crashes with proxy error to kite.com and "internal console not found.

What steps reproduce the problem?

  1. Upgrade Spyder from 5.0.3 to 5.0.4.
  2. Start Spyder, it crashes.
  3. Downgrade to 5.0.3, everything works.

What is the expected output? What do you see instead?

Paste Traceback/Error Below (if applicable)


Traceback (most recent call last):
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/connectionpool.py", line 696, in urlopen
    self._prepare_proxy(conn)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/connectionpool.py", line 964, in _prepare_proxy
    conn.connect()
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/connection.py", line 359, in connect
    conn = self._connect_tls_proxy(hostname, conn)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/connection.py", line 500, in _connect_tls_proxy
    return ssl_wrap_socket(
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/util/ssl_.py", line 428, in ssl_wrap_socket
    ssl_sock = _ssl_wrap_socket_impl(
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/util/ssl_.py", line 472, in _ssl_wrap_socket_impl
    return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
  File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ssl.py", line 500, in wrap_socket
    return self.sslsocket_class._create(
  File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ssl.py", line 1040, in _create
    self.do_handshake()
  File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 54] Connection reset by peer

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/adapters.py", line 439, in send
    resp = conn.urlopen(
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/connectionpool.py", line 755, in urlopen
    retries = retries.increment(
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/urllib3/util/retry.py", line 574, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='release.kite.com', port=443): Max retries exceeded with url: /dls/mac/current (Caused by ProxyError('Cannot connect to proxy.', ConnectionResetError(54, 'Connection reset by peer')))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 2132, in create_window
    main.setup()
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 903, in setup
    plugin_instance = plugin_class(self, configuration=CONF)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/plugin.py", line 236, in __init__
    raise e
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/plugin.py", line 232, in __init__
    self._instantiate_and_register_provider(Provider)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/plugin.py", line 754, in _instantiate_and_register_provider
    provider_instance = Provider(self, provider_config['values'])
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/providers/kite/provider.py", line 83, in __init__
    self.setup_menus()
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/providers/kite/provider.py", line 235, in setup_menus
    installers_available = check_kite_installers_availability()
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/plugins/completion/providers/kite/utils/status.py", line 117, in check_kite_installers_availability
    req = requests.head(url)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/api.py", line 104, in head
    return request('head', url, **kwargs)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/api.py", line 61, in request
    return session.request(method=method, url=url, **kwargs)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/sessions.py", line 542, in request
    resp = self.send(prep, **send_kwargs)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/sessions.py", line 655, in send
    r = adapter.send(request, **kwargs)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/requests/adapters.py", line 510, in send
    raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPSConnectionPool(host='release.kite.com', port=443): Max retries exceeded with url: /dls/mac/current (Caused by ProxyError('Cannot connect to proxy.', ConnectionResetError(54, 'Connection reset by peer')))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/gvizkel/python38/bin/spyder", line 8, in <module>
    sys.exit(main())
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/start.py", line 226, in main
    mainwindow.main(options, args)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 2282, in main
    mainwindow = create_window(app, splash, options, args)
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 2134, in create_window
    if main.console is not None:
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 1156, in __getattr__
    return self.get_plugin(self._INTERNAL_PLUGINS_MAPPING[attr])
  File "/Users/gvizkel/python38/lib/python3.8/site-packages/spyder/app/mainwindow.py", line 169, in get_plugin
    raise SpyderAPIError(
spyder.api.exceptions.SpyderAPIError: Plugin "internal_console" not found!

Versions

  • Spyder version: 5.0.4
  • Python version: 3.8.9
  • Qt version:
  • PyQt version: 5.12.3
  • Operating System name/version: MacOS 10.15.7

Dependencies

PASTE DEPENDENCIES HERE

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
andfoycommented, Jun 16, 2021

According to the requests documentation, the variables set by @gvizkelethy should work as expected, as requests is already picking them. In this case, the error is related to the proxy communication and not with Spyder, we should introduce a Try/Except block to prevent these kind of errors.

0reactions
mrclarycommented, Jun 21, 2021

I can verify that this also occurs when self-signed certificates are used…

2021-06-21 12:52:35,915 [WARNING] [spyder.plugins.completion.plugin] -> Failed to load completion provider from entry point kite = spyder.plugins.completion.providers.kite.provider:KiteProvider
Traceback (most recent call last):
  File "urllib3/connectionpool.pyc", line 699, in urlopen
  File "urllib3/connectionpool.pyc", line 382, in _make_request
  File "urllib3/connectionpool.pyc", line 1010, in _validate_conn
  File "urllib3/connection.pyc", line 411, in connect
  File "urllib3/util/ssl_.pyc", line 449, in ssl_wrap_socket
  File "urllib3/util/ssl_.pyc", line 493, in _ssl_wrap_socket_impl
  File "ssl.pyc", line 500, in wrap_socket
  File "ssl.pyc", line 1040, in _create
  File "ssl.pyc", line 1309, in do_handshake
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)

The self-signed certificate issue is not technically a Spyder problem (we have these issues constantly at my company), but I agree with @andfoy that a try/except block should be used.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spyder changelog - Awesome Python | LibHunt
Official repository for Spyder - The Scientific Python Development ... Issue 15876 - Spyder 5.0.4 crashes with proxy error to kite.com (PR 15889...
Read more >
First Steps — Spyder 5 documentation
If Spyder crashes or you receive an error message, please read the following troubleshooting steps before opening a new issue. There's a good...
Read more >
Kite Client or Package Conflicts Preventing Spyder 4.0 ...
The Spyder 4 dialog box briefly opens and then crashes. Anaconda prompt says that it's a type error in the kite client.
Read more >
Untitled
2mg ativan not working, Ha minwoo ze a tumblr, Atm fees higher one, Local weather ... Szidol helyett, Skype registry proxy, Pictures of...
Read more >
Untitled
Red serious error screen on ps3? ... il hotels marriott, Bhavna chauhan manchester, Brown classic wallpaper design, Oam group australia, Max dps mage...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found