diff options
author | orlnub123 <orlnub123@gmail.com> | 2018-09-12 17:28:53 (GMT) |
---|---|---|
committer | Ethan Furman <ethan@stoneleaf.us> | 2018-09-12 17:28:53 (GMT) |
commit | 0fb9fadd3b3e9e3698647e0b92d49b0b7aacd979 (patch) | |
tree | 0a53251ce3c6655e1a291d2c668e74bbb1318ea7 /Lib/ssl.py | |
parent | f52237400b9960d434c5d0676a3479b8c1e8c869 (diff) | |
download | cpython-0fb9fadd3b3e9e3698647e0b92d49b0b7aacd979.zip cpython-0fb9fadd3b3e9e3698647e0b92d49b0b7aacd979.tar.gz cpython-0fb9fadd3b3e9e3698647e0b92d49b0b7aacd979.tar.bz2 |
bpo-34282: Fix Enum._convert shadowing members named _convert (GH-8568)
* Fix enum members getting shadowed by parent attributes
* Move Enum._convert to EnumMeta._convert_
* Deprecate _convert
Diffstat (limited to 'Lib/ssl.py')
-rw-r--r-- | Lib/ssl.py | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -119,32 +119,32 @@ from _ssl import ( from _ssl import _DEFAULT_CIPHERS, _OPENSSL_API_VERSION -_IntEnum._convert( +_IntEnum._convert_( '_SSLMethod', __name__, lambda name: name.startswith('PROTOCOL_') and name != 'PROTOCOL_SSLv23', source=_ssl) -_IntFlag._convert( +_IntFlag._convert_( 'Options', __name__, lambda name: name.startswith('OP_'), source=_ssl) -_IntEnum._convert( +_IntEnum._convert_( 'AlertDescription', __name__, lambda name: name.startswith('ALERT_DESCRIPTION_'), source=_ssl) -_IntEnum._convert( +_IntEnum._convert_( 'SSLErrorNumber', __name__, lambda name: name.startswith('SSL_ERROR_'), source=_ssl) -_IntFlag._convert( +_IntFlag._convert_( 'VerifyFlags', __name__, lambda name: name.startswith('VERIFY_'), source=_ssl) -_IntEnum._convert( +_IntEnum._convert_( 'VerifyMode', __name__, lambda name: name.startswith('CERT_'), source=_ssl) |