Skip to content

Commit a174f19

Browse files
committed
Also for sync
1 parent 9d9ea8b commit a174f19

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

async_substrate_interface/sync_substrate.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1904,8 +1904,12 @@ def _make_rpc_request(
19041904
raw_websocket_logger.debug(f"WEBSOCKET_SEND> {to_send}")
19051905
ws.send(to_send)
19061906
request_manager.add_request(item_id, payload["id"])
1907+
if len(stringified_payload := str(payload)) < 2_000:
1908+
output_payload = stringified_payload
1909+
else:
1910+
output_payload = f"{stringified_payload[:2_000]} (truncated)"
19071911
logger.debug(
1908-
f"Submitted payload ID {payload['id']} with websocket ID {item_id}: {payload}"
1912+
f"Submitted payload ID {payload['id']} with websocket ID {item_id}: {output_payload}"
19091913
)
19101914

19111915
while True:

0 commit comments

Comments
 (0)