Skip to content

test(watch): reproduce staleness after queue overflow - #16060

Merged
rgrinberg merged 1 commit into
ocaml:mainfrom
rgrinberg:push-omyqnotsntul
Aug 21, 2026
Merged

rgrinberg merged 1 commit into
ocaml:mainfrom
rgrinberg:push-omyqnotsntul

Conversation

@rgrinberg

Copy link
Copy Markdown
Member

Add a private RPC command that injects the file-watcher queue-overflow path and waits for the resulting rebuild. A blackbox test uses it to reproduce the stale glob behavior without requiring macOS or exhausting the operating system's event queue.

This intentionally captures the current broken behavior; a follow-up change will update the expectation alongside the fix.

Related to #16052.

Add a private RPC command that injects a file-watcher queue overflow and waits
for its rebuild to finish. Use it to show that a later source event and
forwarded build leave glob results stale.

Refs ocaml#16052

Signed-off-by: Rudi Grinberg <[email protected]>
@rgrinberg
rgrinberg merged commit 1a6a6d8 into ocaml:main Aug 21, 2026
38 of 39 checks passed
rgrinberg added a commit that referenced this pull request Aug 21, 2026
Memo table cache clearing removed entries before invalidating their
nodes. Existing dependencies consequently retained detached nodes, while
later filesystem events invalidated newly-created entries that could no
longer propagate changes through the active graph.

Invalidate every table entry while it remains reachable, then clear the
table. The queue-overflow reproducer added in #16060 now expects the
subsequent build to observe the new file.

Fixes #16052.

Signed-off-by: Rudi Grinberg <[email protected]>
@Alizter Alizter added this to the 3.25.0 milestone Aug 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants