diff --git a/beacon-chain/sync/initial-sync/blocks_queue.go b/beacon-chain/sync/initial-sync/blocks_queue.go index 0dff2af796b..96ff7e5ce3f 100644 --- a/beacon-chain/sync/initial-sync/blocks_queue.go +++ b/beacon-chain/sync/initial-sync/blocks_queue.go @@ -141,7 +141,7 @@ func (q *blocksQueue) loop() { q.highestExpectedSlot = q.blocksFetcher.bestFinalizedSlot() continue } - log.Debug("Highest expected slot reached") + log.WithField("slot", q.highestExpectedSlot).Debug("Highest expected slot reached") q.cancel() } diff --git a/beacon-chain/sync/initial-sync/round_robin_test.go b/beacon-chain/sync/initial-sync/round_robin_test.go index 3261b58f8ec..f9f0627b153 100644 --- a/beacon-chain/sync/initial-sync/round_robin_test.go +++ b/beacon-chain/sync/initial-sync/round_robin_test.go @@ -117,38 +117,36 @@ func TestRoundRobinSync(t *testing.T) { }, }, }, - - // TODO(3147): Handle multiple failures. - //{ - // name: "Multiple peers with multiple failures", - // currentSlot: 320, // 10 epochs - // expectedBlockSlots: makeSequence(1, 320), - // peers: []*peerData{ - // { - // blocks: makeSequence(1, 320), - // finalizedEpoch: 4, - // headSlot: 320, - // }, - // { - // blocks: makeSequence(1, 320), - // finalizedEpoch: 4, - // headSlot: 320, - // failureSlots: makeSequence(1, 320), - // }, - // { - // blocks: makeSequence(1, 320), - // finalizedEpoch: 4, - // headSlot: 320, - // failureSlots: makeSequence(1, 320), - // }, - // { - // blocks: makeSequence(1, 320), - // finalizedEpoch: 4, - // headSlot: 320, - // failureSlots: makeSequence(1, 320), - // }, - // }, - //}, + { + name: "Multiple peers with multiple failures", + currentSlot: 320, // 10 epochs + expectedBlockSlots: makeSequence(1, 320), + peers: []*peerData{ + { + blocks: makeSequence(1, 320), + finalizedEpoch: 9, + headSlot: 320, + }, + { + blocks: makeSequence(1, 320), + finalizedEpoch: 9, + headSlot: 320, + failureSlots: makeSequence(1, 320), + }, + { + blocks: makeSequence(1, 320), + finalizedEpoch: 9, + headSlot: 320, + failureSlots: makeSequence(1, 320), + }, + { + blocks: makeSequence(1, 320), + finalizedEpoch: 9, + headSlot: 320, + failureSlots: makeSequence(1, 320), + }, + }, + }, { name: "Multiple peers with different finalized epoch", currentSlot: 320, // 10 epochs