Skip to content

fix: keep FCU timestamps at or ahead of wall clock#180

Merged
meyer9 merged 1 commit into
mainfrom
fix/fcu-timestamp-drift
May 12, 2026
Merged

fix: keep FCU timestamps at or ahead of wall clock#180
meyer9 merged 1 commit into
mainfrom
fix/fcu-timestamp-drift

Conversation

@meyer9
Copy link
Copy Markdown
Collaborator

@meyer9 meyer9 commented May 12, 2026

Summary

  • Replaces the 2-second threshold catchup with max(now, lastTimestamp) so FCU timestamps never fall behind wall clock
  • Fixes basic-benchmarks CI flake where the builder sees "FCU arrived too late" on every block, produces empty blocks (0 flashblocks), and the transferonly worker times out waiting for a receipt

Root Cause

Each block cycle (FCU → build → getPayload → newPayload) takes slightly >1s of real time on slow CI runners. The timestamp increments by exactly 1s per block (lastTimestamp + 1), so it gradually drifts behind wall clock. The builder's calculate_flashblocks subtracts a leeway from the target timestamp, sees no remaining time, and builds 0 flashblocks — producing blocks with only the deposit tx and no pool transactions.

The old 2-second guard never triggered because the per-block drift is <2s, but it accumulates over many blocks.

The previous 2-second threshold allowed timestamps to drift behind
wall clock on slow CI runners, causing the builder to compute zero
flashblocks and produce empty blocks. Use max(now, lastTimestamp)
so timestamps never fall behind.
@cb-heimdall
Copy link
Copy Markdown
Collaborator

cb-heimdall commented May 12, 2026

✅ Heimdall Review Status

Requirement Status More Info
Reviews 1/1
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 0
Global minimum 0
Max 1
1
1 if commit is unverified 0
Sum 1

@meyer9 meyer9 merged commit 84b1650 into main May 12, 2026
14 checks passed
@meyer9 meyer9 deleted the fix/fcu-timestamp-drift branch May 12, 2026 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants