Skip to content

land: main-flake-fixes - #500

Merged
ualtinok merged 4 commits into
mainfrom
land/main-flake-fixes
Oct 18, 2026
Merged

ualtinok merged 4 commits into
mainfrom
land/main-flake-fixes

Conversation

@aft-alfonso

@aft-alfonso aft-alfonso Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Accepted agent delivery; branch-keyed search descriptor included.


Summary by cubic

Fixes flaky tests in the aft crate that timed out on loaded Windows runners. The tests now wait on events instead of wall-clock budgets.

Bug Fixes

  • The lane-paused search test installs a ready trigram index up front instead of waiting on a background build.
  • The reuse-fill cold-cap test waits for either the fill result or a queued waiter on the held limiter, not a 2-second timeout.
  • The long-line grep test runs its scan on a frozen clock that advances only when line details are built, while real file reads keep a separate 60-second guard, so it never hits the deadline.
  • The storm setup bind now waits for its reply and fails with the refusal body if refused, instead of timing out.
  • Adds a benchmark descriptor for these test-only changes.

Written for commit 5d22113. Summary will update on new commits.

View guided diff Turn on auto-fix

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no blocking issues remain.

Summary

Replaces short timing assumptions with ready test data and event-based waits.

  • The paused-search test starts with its keyword index ready.
  • The long-line grep test measures scan work with a controllable clock.
  • The reuse-fill test waits for a result or a queued limiter request.
  • The storm setup waits for the bind reply before checking epochs.

Reviews (2) · Last reviewed commit: "mason: separate real read deadlines from..." · Reviewed by Greptile

ualtinok and others added 3 commits October 17, 2026 23:48
…n Windows

lane_paused_initial_build_search_shows_approved_sentence relied on a
background trigram build finishing inside the search's interactive wait
budget. Under Windows module load it did not, both lanes read not-ready
(trigram building, semantic unavailable because the pause was found) and
the search refused with search_lanes_unavailable. The pause lookup itself
matched; the test now installs a ready trigram index up front.

small_chunk_reuse_fill_completes_with_cold_cap_held decided pass/fail by a
2 s recv timeout. It now waits for either the fill's result or a queued
waiter on the held cold-build limiter, which is the defect it guards.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
…nts, not wall clock

long_line_with_many_occurrences_builds_line_details_once_per_arm ran its
scan against the real clock with a 2 s budget, so a loaded Windows runner
could end the scan (scan_deadline_reached) before the count it checks was
decided. The scan clock is now frozen and advances half the budget per
line-details build: one build never reaches the deadline, a per-occurrence
regression reaches it on the second build and fails the count quickly.

subc_storm_same_or_lower_epoch_rebind_is_rejected waited for its setup
bind with the debug-scaled 8 s storm assertion bound and skipped any Error
reply for that bind, so a slow cold bind or a refusal both surfaced as
'timed out waiting for RouteBindAck'. The setup bind (not the subject of
the test) now waits for its reply and fails with the refusal body if the
module refuses it; the scenario watchdog bounds a missing reply.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
Comment thread crates/aft/src/search_index.rs Outdated
Let the existing private clock seam construct a deadline with independent scan and read instants. Production still computes and clamps one instant at the same point and assigns it to both fields, preserving its read and scan budgets.

Keep the long-line test's frozen two-second scan budget and unchanged assertions, but give bounded file reads a real sixty-second hang guard. Retain a three-second pause before the second arm's read: it failed with zero line-detail calls before the fix and now passes. Reusing the frozen read deadline and restoring per-occurrence line-detail work each redden only this test.

Verified the search_index filter (134 passed, 3 ignored), strict Windows-target test compilation, restored focused regression (1 passed), and cargo fmt --check.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
@ualtinok
ualtinok added this pull request to the merge queue Oct 17, 2026
Merged via the queue into main with commit 6314bfe Oct 18, 2026
49 checks passed
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.

1 participant