Skip to content

address comments

3a98421
Select commit
Loading
Failed to load commit list.
Open

Deterministic state syncs #2177

address comments
3a98421
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Apr 4, 2026 in 37m 22s

Code review found 1 important issue

Found 4 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 1
🟡 Nit 0
🟣 Pre-existing 0
Severity File:Line Issue
🔴 Important consensus/bor/heimdall/failover_client.go:121-125 callWithFailover self-imposed timeout causes false MarkUnhealthy on healthy endpoints

Annotations

Check failure on line 125 in consensus/bor/heimdall/failover_client.go

See this annotation in the file changed.

@claude claude / Claude Code Review

callWithFailover self-imposed timeout causes false MarkUnhealthy on healthy endpoints

In `callWithFailover`, the 30-second `attemptTimeout` sub-context is applied unconditionally at line 192, silently capping the 1-minute global timeout that `StateSyncEventsByTime` (and `StateSyncEventsAtHeight`) attempt to set internally — because Go contexts can only narrow deadlines, never extend them. When a large paginated state-sync fetch exceeds 30 seconds on a multi-endpoint (`MultiHeimdallClient`) validator, `isFailoverError` returns `true` (callerCtx has no deadline; err is `context.Dea