Skip to content

Commit

Permalink
checkpoint: into main from release/2.5.2 @ 683d0ac (#19298)
Browse files Browse the repository at this point in the history
Source hash: 683d0ac
Remaining commits: 3
  • Loading branch information
pmaslana authored Feb 20, 2025
2 parents ccfa35c + d1a9b7f commit 90f39c4
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions chia/full_node/full_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,11 @@ async def new_peak(self, request: full_node_protocol.NewPeak, peer: WSChiaConnec
full_node_protocol.RequestBlock(target_peak.height, False),
timeout=10,
)
if target_peak_response is not None and isinstance(target_peak_response, RespondBlock):
if (
target_peak_response is not None
and isinstance(target_peak_response, RespondBlock)
and target_peak_response.block.header_hash == target_peak.header_hash
):
self.sync_store.peer_has_block(
target_peak.header_hash,
peer.peer_node_id,
Expand Down Expand Up @@ -1023,7 +1027,11 @@ async def _sync(self) -> None:
)
)
for i, target_peak_response in enumerate(await asyncio.gather(*coroutines)):
if target_peak_response is not None and isinstance(target_peak_response, RespondBlock):
if (
target_peak_response is not None
and isinstance(target_peak_response, RespondBlock)
and target_peak_response.block.header_hash == target_peak.header_hash
):
self.sync_store.peer_has_block(
target_peak.header_hash, peers[i].peer_node_id, target_peak.weight, target_peak.height, False
)
Expand Down

0 comments on commit 90f39c4

Please sign in to comment.