Skip to content

fix(update): hide post-core update and completion cache child windows on Windows#79694

Open
XuZehan-iCenter wants to merge 1 commit intoopenclaw:mainfrom
XuZehan-iCenter:fix/windows-update-cli-windowsHide
Open

fix(update): hide post-core update and completion cache child windows on Windows#79694
XuZehan-iCenter wants to merge 1 commit intoopenclaw:mainfrom
XuZehan-iCenter:fix/windows-update-cli-windowsHide

Conversation

@XuZehan-iCenter
Copy link
Copy Markdown

Two spawn/spawnSync calls in src/cli/update-cli/ were missing windowsHide: true while sibling calls in the same directory already have it.

  • update-command.ts:1854continuePostCoreUpdateInFreshProcess
  • shared.ts:274tryWriteCompletionCache

This follows the same pattern as #78483 (fix(update): pipe post-core child stdio on Windows) which fixed related Windows console-handle behavior in the same directory.

No functional change on non-Windows platforms.

Real behavior proof

  • Behavior or issue addressed: On Windows, child_process.spawn/spawnSync without windowsHide: true create visible console windows. Two call sites in src/cli/update-cli/ were missing this flag while sibling calls already have it.

  • Real environment tested: Source inspection on current main; Windows behavior validated by logic (the flag is documented in Node.js child_process as Windows-only — no functional change on other platforms).

  • Exact steps or command run after this patch: pnpm test src/cli/update-cli/update-command.test.ts --reporter=verbose

  • Evidence after fix (terminal output):

RUN  v4.1.5 /tmp/doncicx-openclaw
✓ |cli| src/cli/update-cli/update-command.test.ts > resolvePostCoreUpdateChildStdio > returns "pipe" on Windows so the child never inherits the parent console handles 0ms
✓ |cli| src/cli/update-cli/update-command.test.ts > resolvePostCoreUpdateChildStdio > returns "inherit" on non-Windows platforms 0ms

Test Files  1 passed (1)
Tests       24 passed (24)

@openclaw-barnacle openclaw-barnacle Bot added cli CLI command changes size: XS proof: supplied External PR includes structured after-fix real behavior proof. labels May 9, 2026
@clawsweeper
Copy link
Copy Markdown
Contributor

clawsweeper Bot commented May 9, 2026

Codex review: needs real behavior proof before merge.

Summary
Adds windowsHide: true to the post-core update child spawn and completion-cache spawnSync calls in src/cli/update-cli/.

Reproducibility: no. high-confidence live reproduction is available. Source inspection on current main plus the Node contract shows the two child-process calls lack windowsHide and default to visible Windows console behavior, but neither this review nor the PR body includes live Windows console proof.

Real behavior proof
Needs real behavior proof before merge: The PR body only includes source reasoning and unit-test terminal output, and explicitly says live Windows console execution was not tested; please add a redacted Windows screenshot/video/log or terminal output and update the PR body for re-review.

Next step before merge
Needs contributor or maintainer live Windows proof before merge; automation cannot supply the external PR's required real behavior proof.

Security
Cleared: The diff only adds a built-in Node child-process option and does not touch dependencies, workflows, secrets, downloads, or package resolution.

Review details

Best possible solution:

Land this scoped update-cli option change after redacted live Windows proof confirms the child windows no longer appear, with the normal maintainer-owned changelog entry added at merge time.

Do we have a high-confidence way to reproduce the issue?

No high-confidence live reproduction is available. Source inspection on current main plus the Node contract shows the two child-process calls lack windowsHide and default to visible Windows console behavior, but neither this review nor the PR body includes live Windows console proof.

Is this the best way to solve the issue?

Yes from a code perspective: adding windowsHide: true is the narrowest maintainable fix because Node defines it as a Windows-only child-process console hiding option and adjacent update-cli child processes already use it. It still should not merge until real Windows behavior proof is supplied.

Acceptance criteria:

  • Live Windows PowerShell or CMD run demonstrating the post-core update and completion-cache child processes no longer create visible console windows, with private details redacted.
  • pnpm test src/cli/update-cli/update-command.test.ts --reporter=verbose

What I checked:

Likely related people:

  • steipete: GitHub commit history shows steipete introduced the core auto-updater and later maintained the completion refresh/helper surface touched by this PR. (role: introduced behavior and recent maintainer; confidence: high; commits: f442a3539f19, f427ddc220b5, 960fabdaef72; files: src/cli/update-cli/update-command.ts, src/cli/update-cli/shared.ts)
  • vincentkoc: Recent history on update-command.ts includes several focused post-core update and plugin-sync fixes by vincentkoc, including commits near the affected flow. (role: recent adjacent maintainer; confidence: medium; commits: 64ab50e42bad, fcf0561da0ba, 2014c2327b20; files: src/cli/update-cli/update-command.ts)
  • Beandon13: Beandon13 authored the merged related Windows console-handle fix in the same post-core update child path, including the current stdio helper and regression tests. (role: adjacent Windows behavior contributor; confidence: medium; commits: 2d65908f7fa0; files: src/cli/update-cli/update-command.ts, src/cli/update-cli/update-command.test.ts)

Remaining risk / open question:

  • The target Windows console behavior remains unobserved after the patch; the PR body explicitly says live Windows console execution was not tested.

Codex review notes: model gpt-5.5, reasoning high; reviewed against b4376a8bcda5.

Re-review progress:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes proof: supplied External PR includes structured after-fix real behavior proof. size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant