Skip to content

fix(windows): preserve transient runtime admission failures - #2467

Merged
N0zoM1z0 merged 2 commits into
mainfrom
fix/windows-native-transient-retry-2257
Oct 13, 2026
Merged

N0zoM1z0 merged 2 commits into
mainfrom
fix/windows-native-transient-retry-2257

Conversation

@N0zoM1z0

@N0zoM1z0 N0zoM1z0 commented Oct 13, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fixes #2257. Follow-up to the transient native self-test diagnosis in #2266; thanks to @chqcjq for that investigation.

  • Preserve an explicitly retryable native-readiness failure through private runtime acquisition and JavaScript, source-map and WABT analysis error projection.
  • Handle the same real sharing conflict after successful authority caching. The native producer supplies affirmative runtimeAllocation: "not-started" evidence only for failed parent admission, before directory creation; the adapter requires that evidence and exact numeric Win32 32/33 codes.
  • Keep permission errors, opaque messages and unknown allocation state nonretryable. Incomplete cleanup takes precedence, retaining owned resource facts and the original cause.
  • Give transient analysis failures category: unavailable and an appropriate retry instruction. No automatic retries, extra engine calls or new analysis cache.
  • Add an unconditional real-kernel admission regression to the existing Windows native verifier. Move the generic acquisition error to its own leaf module and update all affected consumers.

Verification

Real Windows 11 (10.0.22631.0), official Windows x64 Node 24.18.0, locked production dependencies, official npm 11.16.0 launcher sources as the real application input:

  • CLI normal analysis, actual kernel sharing conflict, release and recovery. Before the fix the failure was unsupported_provider / retryable: false; the correction preserves the reason and reports unavailable / retryable: true.
  • SDK 2.3.1 stdio MCP: normal analysis, warm conflict after authority caching and successful recovery on the same connection. No residual runtime directories.
  • Baseline/candidate CLI normalized-result SHA-256 matches: a24d3c2d9897cccc5ba70e9ee4dce03da88f033a939fe87457136fc5b3a3e2db.
  • Full real native verifier passes, including the new pre-allocation proof case. Its optional independently built process-boundary fixture was not supplied.
  • 99 related tests pass, covering projection, cleanup precedence, runtime admission boundaries, loader behavior, worker cancellation/ownership, source-map and WABT disposition propagation. Injected acquisition failures do not establish real source-map or WABT engine execution.
  • Pinned runtime build, static gate, test-discovery and documentation checks.

No IDA or Ghidra engine was used for this runtime fix. Thirty baseline native self-tests passed: Win32 5 from #1701/#2196 was not reproduced on this host and is not claimed fixed.

Efficiency and limits

Measurements and source pins: experiments/analysis-efficiency/windows-runtime-retry.md.

The successful analysis reply remains unchanged within the tested comparison. The warm error reply decreases from 1,218 to 878 serialized bytes. Complete MCP discovery cost 2,498,686 bytes in the paired source comparison; after upstream Android/SAZ changes, the integration replay discovers 2,517,904 bytes. Bytes are not model tokens; actual model usage was not measured. One controlled process-family run observed a sampled working-set sum of about 694 MiB and a CPU-time lower bound of 26.8 seconds; there is no paired resource baseline and no speedup or resource-saving claim. Heavy verification runs used low priority, one CPU and bounded Node heaps. Only owned intermediate files are cleaned.

Main integration

Rebased onto main a2d8b94dd. The integrated runtime again passed 99 related tests, static/documentation checks and real Windows CLI plus same-connection MCP conflict/recovery. CLI result hashes and MCP successful/error reply sizes remain unchanged; upstream catalogue changes are recorded separately from this fix.

Preserve producer retry disposition through shared analysis errors, and require affirmative pre-allocation evidence for warm native admission failures. Retain cleanup ownership and permission failure semantics.

Verified with real Windows 11 CLI, SDK stdio MCP, kernel sharing conflicts and the native verifier; 99 related tests passed. Performance and verification limits are recorded in experiments/analysis-efficiency/windows-runtime-retry.md. No IDA engine was used for this change.
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@N0zoM1z0

Copy link
Copy Markdown
Collaborator Author

@codex review

Please inspect structured pre-allocation evidence, retry disposition propagation, cleanup precedence, resource ownership and the mandatory real-Windows verifier regression. The verification note separates real-provider evidence from injected boundaries and records performance limitations.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-13T03:37:12.428766Z 255943f Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 255943fbbf

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@N0zoM1z0
N0zoM1z0 merged commit 1724077 into main Oct 13, 2026
39 checks passed
@N0zoM1z0
N0zoM1z0 deleted the fix/windows-native-transient-retry-2257 branch October 13, 2026 03:42
@morluto morluto mentioned this pull request Oct 13, 2026
3 tasks done
@morluto morluto added bug Something isn't working area: runtime Process capture and runtime observation labels Oct 14, 2026
Processware-AI pushed a commit to Processware-AI/rea that referenced this pull request Oct 17, 2026
…2467)

Fixes morluto#2257. Thanks to @chqcjq for the native self-test retry diagnosis in morluto#2266.

Preserve retry disposition through analysis workflows. Native warm admission requires exact sharing/lock codes and affirmative pre-allocation evidence; cleanup ownership takes precedence. No automatic retry or new analysis cache.

Verified with real Windows 11 CLI, same-connection SDK MCP normal/conflict/recovery, the Windows native verifier, 99 focused tests and static/docs gates. Official npm 11.16.0 launcher sources were the application input. No IDA or Ghidra engine was used for this change. Win32 5 was not reproduced; no resolution claim for morluto#1701/morluto#2196. Performance measurements and limits are recorded in experiments/analysis-efficiency/windows-runtime-retry.md.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: runtime Process capture and runtime observation bug Something isn't working

Projects

None yet

2 participants