Repository navigation
Require witnessed requests in hook failure tests - #888
Merged
Merged
Conversation
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: #884
Changelog category (leave one):
Why
A hook request can abort before the test server observes it and still exit successfully in less than 1.5 seconds. The failure tests treated that valid silent exit as impossible. Reusing the same file-context session for another attempt also suppresses its lookup through the hook's existing deduplication.
Scope and risk
The two failure fixtures require a witnessed request within the existing three attempts. Each attempt keeps the zero-exit and empty-output checks and must finish within seven seconds. The final witnessed request keeps its 1.5-second completion bound. Each file-context attempt uses a fresh session fixture so deduplication cannot replace the request being tested.
Compatibility, rollout and rollback
Tests
A private pre-dispatch abort witness makes the original fixture fail its lower-bound assumption. The corrected fixture passes both selected cases with a first aborted request followed by an observed request, and both cases pass without injection.
A control aborting all three attempts still fails the required arrival assertion. No timeout, final arrival assertion or attempt limit is increased.
The two selected cases pass on Node 22.23.2. Node syntax, plugin-sync and diff checks pass. Full remote platform and repository CI remain required; this does not identify the exact stage of the earlier WSL failure.
All remote checks pass on the exact source head, including the WSL platform leg. Later target changes were reviewed separately for composition; that review does not represent a new combined CI run.
AI assistance in the code (leave one; writing this description with AI is fine):
AI-generated: Codex prepared the fixture correction and checked its source, controlled failure witnesses and unchanged hook behavior.
I can explain every line of this diff and how it interacts with the rest of Loom.
Checklist