test: TestCreateReadThenExpireScratch flakes under -race #9

Closed
opened 2026-10-08 06:12:06 +00:00 by eva · 1 comment
Owner

Low priority.

TestCreateReadThenExpireScratch failed once in the race test job on the push run for the Node 24 bump (run 2154). Reading the metadata got 410 when the test wanted 200, so the scratch's TTL ran out before the read. The PR run on the same commit passed, and a rerun of job 4385 passed too. It has nothing to do with the Node bump.

My guess is that the TTL in the test is short enough for a slow -race runner to cross it between create and read.

Fix

Give the read step more headroom, either with a longer TTL for the read half or an injected clock, so the expiry half still runs fast. The test should still check both the read and the expiry.

Acceptance

  • go test -race -run TestCreateReadThenExpireScratch -count=50 ./... passes.
  • Expiry is still asserted.

Revert is git revert.

Low priority. `TestCreateReadThenExpireScratch` failed once in the race test job on the push run for the Node 24 bump (run 2154). Reading the metadata got 410 when the test wanted 200, so the scratch's TTL ran out before the read. The PR run on the same commit passed, and a rerun of job 4385 passed too. It has nothing to do with the Node bump. My guess is that the TTL in the test is short enough for a slow `-race` runner to cross it between create and read. ## Fix Give the read step more headroom, either with a longer TTL for the read half or an injected clock, so the expiry half still runs fast. The test should still check both the read and the expiry. ## Acceptance - `go test -race -run TestCreateReadThenExpireScratch -count=50 ./...` passes. - Expiry is still asserted. Revert is `git revert`.
eva self-assigned this 2026-10-08 06:12:06 +00:00
eva removed their assignment 2026-10-24 03:28:25 +00:00
Author
Owner

Reassigning to ash as gap work per the 10/23 playbook review (implementation isn't Eva's lane; Rex GO 10/23).

Reassigning to ash as gap work per the 10/23 playbook review (implementation isn't Eva's lane; Rex GO 10/23).
linus closed this issue 2026-10-24 15:01:45 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
s1d3sw1ped/scratchbox#9
No description provided.