Commit 471b085d authored by Denis Bilenko's avatar Denis Bilenko

deprecate gevent.sslold

parent 74db0a90
"""OpenSSL-based implementation of SSLObject. """OpenSSL-based implementation of SSLObject.
Use when :mod:`ssl` module is not present. .. warning::
This module is deprecated. Use :mod:`ssl <gevent.ssl>` instead.
""" """
from OpenSSL import SSL from OpenSSL import SSL
from gevent.socket import socket, _fileobject, __socket__, error, timeout, EWOULDBLOCK from gevent.socket import socket, _fileobject, __socket__, error, timeout, EWOULDBLOCK
...@@ -9,6 +11,9 @@ import sys ...@@ -9,6 +11,9 @@ import sys
__all__ = ['ssl', 'sslerror'] __all__ = ['ssl', 'sslerror']
import warnings
warnings.warn("gevent.sslold is deprecated; use gevent.ssl instead (install ssl package from PyPI)", DeprecationWarning, stacklevel=2)
try: try:
sslerror = __socket__.sslerror sslerror = __socket__.sslerror
except AttributeError: except AttributeError:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment