Skip to content

test(site): Fix a timing race in the Redfish burn-in lab - #252

Merged
scotwells merged 2 commits into
feat/manual-inventory-recordsfrom
fix/burnin-lab-race
Nov 29, 2026
Merged

scotwells merged 2 commits into
feat/manual-inventory-recordsfrom
fix/burnin-lab-race

Conversation

@scotwells

Copy link
Copy Markdown
Contributor

Related to #196.

Redfish commissioning tests such as TestCommissioningPassesAServerThatMeetsThePlan flaked on loaded CI runners. The test lab moved its clock past the burn-in, slept 50ms and assumed the worker polled the console meanwhile, so a missed poll made a passing run fail as too short. The lab now waits until the worker stores a sighting on the moved clock.

Test plan

  • With the worker's console poll slowed to 100ms, the old lab fails both reported tests in at least 2 of 3 runs, and this lab passes every run
  • The Redfish worker package passes with the race detector

🤖 Generated with Claude Code

scotwells and others added 2 commits November 28, 2026 19:56
The Redfish lab moved its clock past the burn-in, then slept 50ms and
assumed the worker polled the console in that gap. On a loaded CI runner
the poll can miss it, so the last stored sighting predates the move, the
measured burn-in is near zero, and a passing commissioning fails as too
short. Tests that ran a full burn-in flaked this way.

The lab now waits until the worker stores a sighting on the moved clock.
A move shorter than the persist interval stores nothing new, so it keeps
the short pause. With the worker's poll slowed to 100ms the old lab fails
the burn-in tests and this one passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A burn-in shorter than the persist interval kept the 50ms pause, so the
too-short and restart tests still relied on the worker polling before the
receipt. The lab now waits for the worker's first stored sighting there.
That gap has not been seen to fail, even with the poll slowed to 100ms,
because the first sighting lands well before the receipt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@scotwells
scotwells marked this pull request as ready for review November 29, 2026 02:09
@scotwells
scotwells requested a review from a team as a code owner November 29, 2026 02:09
@scotwells
scotwells requested review from ecv and kevwilliams and removed request for a team November 29, 2026 02:09

@ecv ecv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve.

The Redfish lab now waits until the worker has stored a console sighting on the moved clock before it writes the receipt, instead of sleeping 50ms and hoping a poll landed. That is the race behind the TestCommissioningPassesAServerThatMeetsThePlan failures seen on loaded runners, and the wait has a 10s deadline that fails the test loudly rather than hanging. Test-only.

@scotwells
scotwells merged commit dbc3b41 into feat/manual-inventory-records Nov 29, 2026
15 checks passed
@scotwells
scotwells deleted the fix/burnin-lab-race branch November 29, 2026 02:15
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.

2 participants