gh-102799: use sys.exception() instead of sys.exc_info() in tests (#103293)

This commit is contained in:
Irit Katriel 2023-04-06 11:08:25 +01:00 committed by GitHub
parent a44568b80d
commit 482b6eeadc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 68 additions and 71 deletions

View file

@ -253,7 +253,7 @@ def requires_tls_version(version):
def handle_error(prefix):
exc_format = ' '.join(traceback.format_exception(*sys.exc_info()))
exc_format = ' '.join(traceback.format_exception(sys.exception()))
if support.verbose:
sys.stdout.write(prefix + exc_format)