def enforce_no_py_open_ssl()

in azure/datalake/store/lib.py [0:0]


def enforce_no_py_open_ssl():
    try:
        from requests.packages.urllib3.contrib.pyopenssl import extract_from_urllib3
    except ImportError:
        # in the case of debian/ubuntu system packages, the import is slightly different
        try:
            from urllib3.contrib.pyopenssl import extract_from_urllib3
        except ImportError:
            # if OpenSSL is unavailable in both cases then there is no need to "undo" it.
            return
    extract_from_urllib3()