bpo-37961: Fix regression in tracemalloc.Traceback.__repr__ (GH-23805)

Regression in 8d59eb1b66.
(cherry picked from commit 051b981867)

Co-authored-by: Daniel Hahler <git@thequod.de>
This commit is contained in:
Miss Islington (bot) 2020-12-16 14:01:14 -08:00 committed by GitHub
parent 1662868490
commit 78062e07bc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 22 additions and 1 deletions

View file

@ -226,7 +226,7 @@ class Traceback(Sequence):
return str(self[0])
def __repr__(self):
s = "<Traceback %r" % tuple(self)
s = f"<Traceback {tuple(self)}"
if self._total_nframe is None:
s += ">"
else: