1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-09-08 05:58:43 +02:00

Merge pull request #723 from lethliel/improve_error_message_on_ssl_version_mismatch

improve SSLError message
This commit is contained in:
Marco Strigl
2020-02-06 13:31:54 +01:00
committed by GitHub

View File

@@ -172,6 +172,8 @@ def run(prg, argv=None):
except RPMError as e:
print(e, file=sys.stderr)
except SSLError as e:
if 'tlsv1' in str(e):
print('The python on this system does not support TLSv1.2', file=sys.stderr)
print("SSL Error:", e, file=sys.stderr)
except SSLVerificationError as e:
print("Certificate Verification Error:", e, file=sys.stderr)