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.

ImportError: cannot import name 'OP_NO_TICKET' from 'urllib3.util.ssl_'

See original GitHub issue

Describe the bug The just released version 1.23.0 will spit out the error in the title if you try to import botocore.utils, which precludes almost any use of the library.

Steps to reproduce My environment: OS: macOS Big Sur (11.4) Python: 3.7.12 (virtualenv ultimately from brew installed version) pyOpenSSL: 20.0.0

Install botocore 1.23.0 with pip3 install botocore==1.23.0. Run import botocore.utils.

Expected behavior There should not be an import error (and I believe this is the first version where this happens as it doesn’t in 1.22.12).

Debug logs (I cannot set the debug logger without getting the import error, so I can only show the import error.)

In [1]: import botocore.utils
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-1-918253be0bba> in <module>
----> 1 import botocore.utils

~/docs/venv/barrypy3/lib/python3.7/site-packages/botocore/utils.py in <module>
     30 import botocore
     31 import botocore.awsrequest
---> 32 import botocore.httpsession
     33 from botocore.compat import (
     34     json, quote, zip_longest, urlsplit, urlunsplit, OrderedDict,

~/docs/venv/barrypy3/lib/python3.7/site-packages/botocore/httpsession.py in <module>
      8 from urllib3 import PoolManager, proxy_from_url, Timeout
      9 from urllib3.util.retry import Retry
---> 10 from urllib3.util.ssl_ import (
     11     ssl, OP_NO_SSLv2, OP_NO_SSLv3, OP_NO_COMPRESSION, OP_NO_TICKET,
     12     PROTOCOL_TLS, PROTOCOL_TLS_CLIENT, DEFAULT_CIPHERS,

ImportError: cannot import name 'OP_NO_TICKET' from 'urllib3.util.ssl_' (/Users/barry/docs/venv/barrypy3/lib/python3.7/site-packages/urllib3/util/ssl_.py)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:19
  • Comments:13 (2 by maintainers)

github_iconTop GitHub Comments

20reactions
nateprewittcommented, Nov 9, 2021

Botocore 1.23.1 has been released with fix for this. Please let us know if you’re still experiencing issues.

3reactions
ben-thwaitescommented, Nov 8, 2021

+1

Read more comments on GitHub >

github_iconTop Results From Across the Web

from urllib3.util.ssl_ import ( ImportError: cannot import name ssl
I have an automation solution built in python. The solution can be run from both cmd or pycharm of course. 2 options to...
Read more >
cannot import name 'ssl' from 'urllib3.util.ssl_' #653 - GitHub
I am trying to run the depthai_demo.py with -gt cv arguments from Visual Studio Code and receive the "cannot import name 'ssl' from...
Read more >
Importerror cannot import name ssl from urllib3 util ssl_ : Fix
importerror cannot import name ssl from urllib3 util ssl_ error comes because of an incompatible version of python with urllib3 module.
Read more >
cannot import name 'OP_NO_TICKET' from 'urllib3.util.ssl_'
I started running airflow locally and while running docker specifically: docker-compose run -rm web server initdb I started seeing this error.
Read more >
Python caller output to S3 Uploader: an error 'Python Exception
If all parts are connected, I am getting an error: Python Exception <ImportError>: cannot import name 'ssl' from 'urllib3.util.ssl_' ...
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