Skip to content

Commit 8e8e803

Browse files
committed
fix(syncer): subj init death loop
1 parent 6826db2 commit 8e8e803

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

sync/syncer_head.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,11 @@ func (s *Syncer[H]) incomingNetworkHead(ctx context.Context, head H) error {
227227

228228
// verify verifies given network head candidate.
229229
func (s *Syncer[H]) verify(ctx context.Context, newHead H) error {
230-
sbjHead, _, err := s.subjectiveHead(ctx)
230+
// TODO(@Wondertan): This has to be subjective head.
231+
// But due to an edge case during subjective init, this might be an expired tail
232+
// triggering subjective reinit death loop.
233+
// This can and will be fixed with bsync,
234+
sbjHead, err := s.localHead(ctx)
231235
if err != nil {
232236
log.Errorw("getting subjective head during new network head verification", "err", err)
233237
return err

0 commit comments

Comments
 (0)