From 148a098ca6dac5033a774428873b06f9dbc26d15 Mon Sep 17 00:00:00 2001 From: mahmoud Date: Tue, 5 May 2026 18:37:19 +0000 Subject: [PATCH] avoid format on the hot send path --- tractor/ipc/_chan.py | 4 ++-- tractor/msg/_ops.py | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/tractor/ipc/_chan.py b/tractor/ipc/_chan.py index 10a800e4..0bf254d7 100644 --- a/tractor/ipc/_chan.py +++ b/tractor/ipc/_chan.py @@ -326,8 +326,8 @@ class Channel: __tracebackhide__: bool = hide_tb try: log.transport( - '=> send IPC msg:\n\n' - f'{pformat(payload)}\n' + '=> send IPC msg\n\n' + # f'{pformat(payload)}\n' ) # assert self._transport # but why typing? await self._transport.send( diff --git a/tractor/msg/_ops.py b/tractor/msg/_ops.py index a134306f..fe5929f6 100644 --- a/tractor/msg/_ops.py +++ b/tractor/msg/_ops.py @@ -308,12 +308,12 @@ class PldRx(Struct): pld: PayloadT = self._pld_dec.decode(pld) log.runtime( f'Decoded payload for\n' - # f'\n' - f'{msg}\n' - # ^TODO?, ideally just render with `, - # pld={decode}` in the `msg.pformat()`?? - f'where, ' - f'{type(msg).__name__}.pld={pld!r}\n' + # # f'\n' + # f'{msg}\n' + # # ^TODO?, ideally just render with `, + # # pld={decode}` in the `msg.pformat()`?? + # f'where, ' + # f'{type(msg).__name__}.pld={pld!r}\n' ) return pld except TypeError as typerr: