use %r to __repr__ objects

This avoids calculating __repr__ unless we are going to log.
This commit is contained in:
Michael Kaye 2019-10-24 18:17:33 +01:00
parent f85b9842f0
commit 9eebc1e73b
3 changed files with 4 additions and 4 deletions

View file

@ -122,10 +122,10 @@ class TransportLayerClient(object):
Deferred: Results in a dict received from the remote homeserver.
"""
logger.debug(
"backfill dest=%s, room_id=%s, event_tuples=%s, limit=%s",
"backfill dest=%s, room_id=%s, event_tuples=%r, limit=%s",
destination,
room_id,
repr(event_tuples),
event_tuples,
str(limit),
)