diff --git a/docs/plans/v1/_files/internal/limiter/limiter_test.go b/docs/plans/v1/_files/internal/limiter/limiter_test.go index bf90588..6ab30e2 100644 --- a/docs/plans/v1/_files/internal/limiter/limiter_test.go +++ b/docs/plans/v1/_files/internal/limiter/limiter_test.go @@ -32,10 +32,10 @@ func TestParallelAndQueue(t *testing.T) { go func() { rel, waited, err := l.Acquire(ctx, "alpha", "m") if err == nil { - defer rel() if waited < 40*time.Millisecond { err = errors.New("third acquire did not wait") } + rel() // release before reporting, so the final count check cannot race it } got3 <- err }() diff --git a/docs/plans/v2/README.md b/docs/plans/v2/README.md index 5194a88..b743259 100644 --- a/docs/plans/v2/README.md +++ b/docs/plans/v2/README.md @@ -82,3 +82,8 @@ reason. per argv element, so check 3 could never pass. Test fault (mine): the body now goes through a file (`-d @file`). Ornith diagnosed it correctly. Resumed from the working tree with the corrected script. +- 2026-09-25, task 05, third session: `TestParallelAndQueue` (v1 given `limiter_test.go`) failed + once under full-suite `-race` load with `after releases: inflight 1 queued 0`. Test fault + (mine): the third acquirer sent its result before its deferred release ran, so the final + count check could observe one slot still held. The given file now releases before reporting. + Ornith found it and measured the flake rate rather than editing the protected file.