Repository navigation
fix(artifacts): preserve iNES shutdown ownership and I/O failures - #11739
ShuaixinHuang wants to merge 23 commits into
Conversation
…al-open-11154-20261116
…repair-11154-20261116 # Conflicts: # src/artifacts/InesArtifactReader.ts # tests/boundary/filesystem/fileHandleChunks.test.ts # tests/boundary/filesystem/inesCancellation.test.ts
…repair-11154-20261116
…file
The Windows-only case at `clientConfigurationEnvironment.test.ts:226` wrote
`rea_mcp_input_schema_profile: "full"`. That profile was retired: the reader
now refuses it ("REA_MCP_INPUT_SCHEMA_PROFILE accepts only \"compact\" …"),
so `configureClientConfiguration` returned `failed/readback` before writing
and the case failed on every Windows run, including main's own
`Windows capability and package lane`.
The case has no Windows dependency — it passes an explicit `configPath` and
the Kimi write dialect is the same everywhere — so it now runs on every
platform, which is what let the stale value rot unnoticed. The fixture keeps
the lowercase explicit key the case is about, with the supported value.
Verified on `main` `d6bcfc10`: the same fixture driven through
`configureClientConfiguration(..., "win32")` on this host reproduced
`{"status":"failed","reason":"readback"}` with the retired value and now
returns `{"status":"configured"}` with `compact`. The file's 75 cases pass
here (66 run, 9 platform-conditioned skips) and `check:fast` passes.
…alue-11154 # Conflicts: # tests/boundary/mcp/decompileAllCaveats.test.ts # tests/boundary/mcp/environmentServeMcp.test.ts
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
[Medium impact] The reviewed changes appear safe to merge; no new blocking issue was established. SummaryThe PR keeps iNES reads and final source checks owned until they finish.
No new actionable findings were established. Review was source-based; no tests were run. Whether this PR has been superseded could not be verified because GitHub access required authentication. DiagramsequenceDiagram
participant Caller
participant Reader as InesArtifactReader
participant Scope as ArtifactResourceScope
participant Stream as Region stream
participant File as Owned descriptor
Caller->>Reader: close()
Reader->>Reader: Stop admission and abort lifecycle
Reader->>Scope: close()
Scope->>Stream: Wait for producer completion and readable retirement
Note over Scope: Also wait for admitted source checks
Scope-->>Reader: Work retired
opt Reader owns descriptor
Reader->>File: close()
end
Reader-->>Caller: Shutdown complete
Reviews (3) · Last reviewed commit: "Merge remote-tracking branch 'origin/mai..." · Reviewed by Greptile |
Summary
Closing an iNES reader during a region read or final identity validation could release its extraction-owned descriptor before admitted work retired. Buffered streams and paused inventories could continue after closure; a shared descriptor-read race could replace a physical I/O failure with cancellation.
Use the existing resource scope to stop producers and join producer completion plus readable retirement. Admit final source validation independently, preserve borrowed-descriptor ownership and failed-close retry ownership, and retain a physical failed-read outcome until it is forwarded. The doctor fixture publishes readiness only after installing its SIGTERM handler.
Resubmission and prerequisites
Replaces #11154 at the human owner's request after repairing its inherited CI failures. Preserve iNES cancellation, physical I/O failures and descriptor ownership. The original feature commits are preserved; prior review and baseline reproduction evidence remain available in #11154.
Qualified head
bb2022f8cincorporates main552d1c710, including the merged shared CI repair #11727. It also explicitly includes the missing-installation JVM-probe repair #11732; that prerequisite requires review. The new comparison drops the shared fixes already accepted upstream.Executed validation
Linux, Node 24.22.1 / npm 11.9.0:
npm run test:focused -- tests/boundary/cli/doctorCancellation.test.ts tests/boundary/filesystem/fileHandleChunks.test.ts tests/boundary/filesystem/inesCancellation.test.ts— Test Files 3 passed (3); Tests 65 passed (65); required build passed.npm run check:fast, normal commit/pre-push hooks, andgit diff --checkpassed.Hosted CI is running for this replacement. Native Windows/macOS and the complete monolithic suite were not run locally. Checked-in independent producer witnesses were exercised by the selected tests; producer generation was not rerun unless named above.
Author readiness
Human owner: @ShuaixinHuang
The initial readiness declaration is carried from #11154; the repository permits later corrective pushes without a new initial declaration.