Skip to content

Windows: wait up to 1.5 s for the watcher before reporting changed files - #1009

Merged
ualtinok merged 4 commits into
mainfrom
land/windows-flush-wait
Oct 26, 2026
Merged

ualtinok merged 4 commits into
mainfrom
land/windows-flush-wait

Conversation

@aft-alfonso

@aft-alfonso aft-alfonso Bot commented Oct 26, 2026

Copy link
Copy Markdown

On a loaded Windows machine the file watcher's acknowledgement of a finished command's flush marker can arrive after the 300 ms window, so the changed-files report was marked incomplete even though every file had been seen (2-4 of 50 runs under load in the investigation). Ufuk approved a Windows-only 1.5 s cap; macOS and Linux stay at 300 ms. The wait still ends as soon as the acknowledgement arrives.

Tests: late acknowledgements at 400 ms and 900 ms complete on Windows; an acknowledgement past the cap still reports incomplete on every platform. Passed on native Windows, including the whole bash_changed_files set in parallel.

ualtinok and others added 4 commits October 26, 2026 23:12
A finished command's changed-files report waits for a flush marker to be
acknowledged by the watcher. On loaded native Windows runners building the
marker file can take most of a second, so the 300 ms shared cap reported a
complete set of files as incomplete. Windows now caps the wait at 1.5 s;
macOS and Linux stay at 300 ms. The wait still ends as soon as the
acknowledgement arrives, and a command whose ack misses the cap still
reports incomplete with the existing text.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
(cherry picked from commit 771ca837116d3982e6fa02987a16375eef02805c)
The late-acknowledgement test waited with the production cap, so on a busy
Windows runner the helper's thread scheduling sat on top of the production
allowance and the test timed out. It now waits with its own budget and the
cap's size is checked separately. The incomplete case still asserts that a
wait gives up before a late acknowledgement can arrive.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
(cherry picked from commit 543302f72a593d9842b860f36a7b9ece0715db2e)
The flush wait is back to one recv_timeout with no test seam in
FlushControl. The delay that stands in for a slow watcher now lives in the
test helper thread, which holds back only its first acknowledgement.
The release note states the Windows change in user terms.

Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
(cherry picked from commit 25c6fc7799939fea59f8df798b95713b9806817f)
Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
@ualtinok
ualtinok added this pull request to the merge queue Oct 26, 2026
Merged via the queue into main with commit 17cddd8 Oct 26, 2026
90 checks passed
@ualtinok
ualtinok deleted the land/windows-flush-wait branch October 26, 2026 23:20
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