Skip to content

fix(zcode): use patched Node for Windows acceptance - #2008

Merged
hidb4ai merged 1 commit into
oceanbase:masterfrom
knqiufan:codex/fix-zcode-windows-exit-1999
Oct 15, 2026
Merged

hidb4ai merged 1 commit into
oceanbase:masterfrom
knqiufan:codex/fix-zcode-windows-exit-1999

Conversation

@knqiufan

@knqiufan knqiufan commented Oct 15, 2026 •

Copy link
Copy Markdown
Collaborator

Which issue or RFC does this PR close?

Refs #1999. Also addresses the Windows process-exit failure reported by the ZCode acceptance on #1972.

Rationale for this change

The linked job passes the plugin Node tests and one complete controlled CLI acceptance, then its second acceptance exits with host_process_exit_3221226505 in P3-03. This matches the native-exit failure tracked in #1999. #1972 changes only two RFC Markdown files; the workflow runs on every PR synchronization, including documentation changes.

The passing run 38377096482 tested merge 4dd04f2d against master ee50b36d; the failing run tested merge 644b5847 against master 7f38426e. GitHub tests the synthesized merge with the current base, so these CI runs also contain different master changes despite the documentation-only PR diff.

The pinned Node 24.15.0 contains a Windows shutdown race fixed by nodejs/node#61999: a delayed worker task can post to an already-closing libuv async handle. On Windows, the upstream redirect/fetch/exit reproduction fails 40/40 times with 0xC0000409 on 24.15.0 and exits normally 40/40 times on 24.21.0. Node 24.20.0 also fixes that reproduction, but the actual ZCode plugin host test aborts there with the separate fs-event.c path assertion; 24.21.0 contains its fix, nodejs/node#65118.

The original failing job retained no process stderr, so its exact native assertion cannot be recovered. This change removes verified runtime crash paths and retains content-free signatures to distinguish any recurrence. The same numeric return code alone cannot establish the failing native component.

What changes are included in this PR?

  • Pin the Windows acceptance job to Node 24.21.0 and document the two upstream fixes.
  • Retain the failed prompt process's return code, complete result-event count and recognized native assertion in its existing summary artifact.
  • Preserve the process failure if a crash truncates its final JSON frame. Successful invocations still require valid JSON output.
  • Add subprocess regressions with synthetic stderr and forced nonzero exits for both recognized signatures, failure after result emission, truncated output, and exclusion of private diagnostic text.

Are there any user-facing changes?

The acceptance runtime and failure summaries change. Each invocation must still exit successfully; no retry or exit-code suppression is added. Public APIs and persisted application data formats are unchanged.

How was this change tested?

Local execution used Windows, the pinned ZCode source 29628c9acdb81b703bbd4080c207a0e7ce5e276e / CLI 0.16.9, and checksummed official Node binaries.

Windows CI run 38674979962 passed on attempt 1 at commit b450f854: a fresh host build, 81 Python harness tests, all 23 plugin Node tests, both independent controlled CLI acceptances, and all four Pi-to-ZCode cases. CI used Node 24.21.0 and pnpm 10.33.2; live-model cases were deselected.

  • uv run --locked --no-sync pytest evaluation/zcode_guidance/tests tests/test_zcode_acceptance_protocol.py tests/test_zcode_acceptance_host.py -q: 81 passed with Python 3.12.
  • node --test integrations/zcode/plugins/powercontext/tests/*.test.mjs with Node 24.21.0 and ZCODE_CLI_BIN: all 23 passed, including actual native host discovery and controlled HTTP fixtures.
  • uv run --locked --no-sync pytest tests/e2e/test_zcode_host_acceptance.py -m 'zcode_host_acceptance and not zcode_live_model' --zcode-acceptance-output <temporary-directory> -q: two independent actual CLI + real SQLite Server acceptances passed, with two live-model cases deselected. Each completed P3-01 through P3-09 with a fresh profile, Scope and database.
  • uv run --locked --no-sync pytest tests/e2e/test_cross_host_work_continuity.py -m cross_host_acceptance --cross-host-acceptance-output <temporary-directory> -q: all four actual Pi-to-ZCode cases passed with controlled inference and real persistence.
  • Focused host/protocol subprocess tests also passed on Python 3.14 (15 tests).
  • Upstream redirect/fetch/exit reproduction: Node 24.15.0 fails 40/40 with the async-handle assertion; Node 24.21.0 passes 40/40.
  • python -m evaluation.zcode_guidance.pin --check, python scripts/check_workflow_actions.py, Ruff and git diff --check passed.
  • uv run prek run -a: all hooks except native Windows ty-check passed. That check reports existing POSIX-only attributes such as os.O_NOFOLLOW, fcntl.flock and os.mkfifo; uv run --locked --no-sync ty check --python-platform linux passed separately.

AI usage statement

OpenAI Codex assisted with CI investigation, implementation and validation. The author is responsible for the changes.

@hidb4ai hidb4ai left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@hidb4ai
hidb4ai merged commit 9b5712e into oceanbase:master Oct 15, 2026
36 checks passed
@hidb4ai hidb4ai added the 1.4.0 v1.4.0 release tracking label Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1.4.0 v1.4.0 release tracking

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants