Skip to content

Commit

Permalink
workaround logging
Browse files Browse the repository at this point in the history
  • Loading branch information
benbierens committed Dec 2, 2024
1 parent 190719a commit ff0e0ee
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions codex/blockexchange/engine/engine.nim
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ proc stop*(b: BlockExcEngine) {.async.} =

trace "NetworkStore stopped"

proc `$`*(blkAddrs: seq[BlockAddress]): string =
proc formatAddrs(blkAddrs: seq[BlockAddress]): string =
result &= "["
for addr in blkAddrs:
result &= ($addr & " ")
Expand All @@ -142,7 +142,7 @@ proc sendWantHave(
for p in peers:
if p notin excluded:
let toAsk = addresses.filterIt(it notin p.peerHave)

Check warning on line 144 in codex/blockexchange/engine/engine.nim

View check run for this annotation

Codecov / codecov/patch

codex/blockexchange/engine/engine.nim#L144

Added line #L144 was not covered by tests
trace "Sending wantHave request", toAsk, peer = p.id
trace "Sending wantHave request", toAsk = formatAddrs(toAsk), peer = p.id
await b.network.request.sendWantList(

Check warning on line 146 in codex/blockexchange/engine/engine.nim

View check run for this annotation

Codecov / codecov/patch

codex/blockexchange/engine/engine.nim#L146

Added line #L146 was not covered by tests
p.id,
toAsk,
Expand All @@ -152,7 +152,7 @@ proc sendWantBlock(
b: BlockExcEngine,
addresses: seq[BlockAddress],
blockPeer: BlockExcPeerCtx): Future[void] {.async.} =
trace "Sending wantBlock request to", addresses, peer = blockPeer.id
trace "Sending wantBlock request to", addrs = formatAddrs(addresses), peer = blockPeer.id
await b.network.request.sendWantList(
blockPeer.id,
addresses,
Expand Down

0 comments on commit ff0e0ee

Please sign in to comment.