Skip to content

Windows hooks start under unconverted paths, and six more setup and install fixes from outside reports - #4682

Merged
capy-ai[bot] merged 3 commits into
mainfrom
fix/outside-setup-install
Nov 22, 2026
Merged

capy-ai[bot] merged 3 commits into
mainfrom
fix/outside-setup-install

Conversation

@garrytan

@garrytan garrytan commented Nov 22, 2026 •

Copy link
Copy Markdown
Owner

Seven install and setup bugs reported by outside contributors are fixed, each with a test that fails on main: Windows hooks under an apostrophe home or with path conversion off, two misleading ./setup --status rows, owner-only files in Bun's shared cache, a leftover /connect-chrome alias, a doctor false alarm, and harness installs ignoring disabled_skills.
Nothing to do after merge; the next ./setup or upgrade picks it up.

What changed

People on Windows reported that every TypeScript hook died with "Module not found" when their home folder held an apostrophe or they had MSYS_NO_PATHCONV=1 set. Each hook shim and gstack-hook-check now hand Bun a C:/… path, and ./setup turns Git Bash's path conversion back on for the programs it starts.

Report What was wrong Fix
#4386 (abyss-node) On Git Bash, a path holding ' (or any path with MSYS_NO_PATHCONV=1) reaches native Bun as /c/x, so every TypeScript hook failed and gstack-hook-check refused all of them Each hook shim and the checker pass Bun a cygpath -m path on Windows, and the checker reads those paths literally; ./setup unsets MSYS_NO_PATHCONV and MSYS2_ARG_CONV_EXCL for what it starts
#4164 / #4190 (NekoCCN, ElNeMeR70) ./setup --status failed every --prefix install on ../qa/sections/… The checker also tries the prefixed sibling ../gstack-qa/…
#4420 (exGeni) A gone row said "the next setup drops this row" (only --refresh-registered does); the checkout's own Codex render showed as an unregistered project install Text names the real command; that render is skipped
#4288 (exGeni) bun install and the Playwright install ran under setup's umask 077, leaving 0600 files in Bun's shared cache Those installs run under umask 022; setup itself keeps 077
#4308 / #4319 (dipbazz, szsunyuan) Disabling /open-gstack-browser left /connect-chrome registered gstack-relink removes the alias's generated SKILL.md through the ownership check; an edited one is backed up and the user's other files stay
#4324 (alexanderhaire) gstack-doctor inside a gstack checkout flagged gstack's own CLAUDE.md as a pasted skill list That file is skipped and named in the row
#4548 (stevewandler) OpenClaw, Hermes and Dots registrations carried skills turned off with disabled_skills The payload drops them
Why

"Every TypeScript hook dies with Module not found" (#4386) and six smaller reports: install and setup should work for everyone who installs gstack, including Windows users and people who turn skills off.

Blast radius

Install scripts and hook launchers. The cygpath lines run only when OSTYPE is msys or cygwin and cygpath exists, so Linux and macOS behaviour is unchanged (script ran: the destructive guard still denies rm -rf / on Linux). The umask change applies only inside the two install subshells (test asserts setup's umask is still 0077 afterwards). Alias cleanup removes only gstack's generated file (tested with a user's file in the folder and an edited SKILL.md).

Security read

Touches install scripts and hook launchers, so each was read for spawn and permission effects. No new dependencies, network calls or CI changes. Outside branches were read as text only and rebuilt on main.

Not fixed here

./setup under a home folder holding an apostrophe still hands Bun unconverted /c/… paths at several call sites (the Codex preflight at setup:1414 is the first), and #4386 lists further failures past that point. Those need changes we can't verify without a Windows machine with such a home, so this PR fixes the hooks and the MSYS_NO_PATHCONV case only.

Test Coverage

12 of 14 changed paths have a test (86%); value-weighted 11 of 14 (79%). Tests: 1862 → 1862 files (+0 new files; 2 tests added in existing files during review). Gaps left as proposals: a non-checkout .agents/skills/gstack registry row, and disabled_skills naming gstack or gstack-upgrade. Weak: the Playwright umask is a source check.
Tests ran: targeted 197 (2 skipped: they need a real Hermes source and a real OpenClaw binary).

Pre-Landing Review

Two rounds. The first full pass found three blockers from the second-model review: two were fixed in this PR (the alias cleanup could delete a whole alias folder; hook paths were glob-expanded before Bun saw them), each with a test that fails without the fix, and one is in unchanged code (below). The second, scoped pass over the fix found nothing blocking.

Deferred findings

Blocking findings in code this PR did not change (review scope: frozen). They stay on this PR and are not filed as issues.

  • Deferred: CRITICAL setup:1414 under a checkout path holding an apostrophe, Git Bash leaves the Codex preflight's script path unconverted and native Bun exits; setup:7's unset does not cover that case (unchanged code at 1414-1417, same on main)
Review notes

Below the blocking floor (advisory, informational, test-gap or wording items); recorded here and not fixed in this PR.

  • INFORMATIONAL test/harness-register.test.ts:158 sourceSkills callers in tests read disabled_skills from the ambient state root
  • INFORMATIONAL bin/gstack-hook-check:248 Cygwin lookup keys use /cygdrive while shellPath yields /c (not a regression)
  • INFORMATIONAL bin/gstack-hook-check:192 a failed cygpath reports every entry as a bundle failure instead of naming cygpath
  • INFORMATIONAL setup:7 setup drops a user's narrow MSYS2_ARG_CONV_EXCL for everything it starts
  • INFORMATIONAL sf-69051cf5ea2a security finding, details recorded privately
  • INFORMATIONAL sf-8e5745c5c3e9 security finding, details recorded privately
  • INFORMATIONAL bin/gstack-hook-check:236 same as red-team#1: helper paths still glob-expanded
  • INFORMATIONAL bin/gstack-relink:410 same as red-team#2: false backup when a render differs from the checkout
Exploratory QA

Pass: functional smoke, 2 probes. gstack-doctor inside a gstack checkout reports its CLAUDE.md row ok and names the skip (#4324); the destructive guard hook on Linux still denies rm -rf /. Windows branches were not probed on Linux; the Windows CI jobs cover them.

Eval Results

No prompt-related files changed — evals skipped.

Scope Drift

Scope Check: CLEAN

Plan Completion

Plan completion audit: not run (no plan is bound to this branch; bug fix, plan exempt).

Verification Results

No plan verification items (bug fix, no plan file).

Issues

Refs #4164
Refs #4288
Refs #4308
Refs #4324
Refs #4386
Refs #4420
Refs #4548
Refs #4682
Refs p1v/outside-voice#1
Refs p1v/outside-voice#3

TODOS

No TODO items completed in this PR.

Documentation

Status: updated. One factual edit, no blockers.

Scope: branch fix/outside-setup-install, commits c2b4f0d to cf86d3d (2 commits, 30 files): Windows hook path handling (#4386), ./setup --status notes and filtering (#4164, #4420), the install umask (#4288), removing the connect-chrome alias when its skill is disabled (#4308), gstack-doctor skipping gstack's own CLAUDE.md (#4324), and disabled_skills for OpenClaw, Hermes and Dots registrations (#4548). No staged, unstaged or new files.

Documentation health:

  • docs/troubleshooting.md: Updated. The claude-md-skill-list section now notes that gstack's own CLAUDE.md is skipped inside a gstack checkout.
  • README.md: Current
  • CONTRIBUTING.md: Current
  • docs/hosts.md: Current
  • docs/loadouts.md: Current
  • docs/uninstall.md: Current
  • docs/capy-install.md: Current
  • docs/ADDING_A_HOST.md: Current
  • docs/CONTRIBUTOR_REFERENCE.md: Current
  • docs/inventory.md: Current
  • docs/PROJECT_STRUCTURE.md: Current
  • gstack-upgrade/SKILL.md.tmpl: Current

Coverage debt: This is a bug-fix release with no new commands, flags or settings. The new ./setup --refresh-registered hint in --status output is covered in docs/hosts.md and docs/ADDING_A_HOST.md. The Windows hook path fix has only its changelog entry, with no troubleshooting entry for hooks failing with "Module not found" (minor gap).

Diagram drift: none found.

Tests
  • Targeted: bun test on gstack-doctor-launch, harness-register, host-conformance, relink, setup-hook-syntax-gate and setup-production-deps: 197 pass, 2 skip, 0 fail
  • Full free suite in CI (free-tests.yml run 44999092743 at this head): green; macOS and Windows jobs green at this head
Agent notes

Agent notes

Lane GSTA-801 for GStack Minder (GST-3483).

Approvals

No approvals recorded for branch fix/outside-setup-install.
Plan: exempt: bug fix rebuilt from outside reports, with failing-first tests
Plan check: exempt bug fix

REVIEW_LOOP: passes=2 blocking_found=3 deferred=1 noted=9 fixed=2 scope=frozen fix_checks=1 dispatches=2
Gate edits: none detected (10 listed, 2 read; patterns: RH-1,RH-3,RH-4,RH-12,RH-13,RH-14,RH-15,RH-16; unlisted idioms: none)

{
  "schema_version": 1,
  "pr": 4682,
  "head": "518975b1699e3a2971581b2140e9024de87c8322",
  "version": "1.102.2.0",
  "base": "main",
  "gate": {
    "targeted": {
      "pass": 197,
      "fail": 0,
      "skip": 2
    }
  },
  "calls": 44,
  "session_kind": "unattended",
  "run": "ship-4682-run1",
  "head_tree": "e65c33e3b17339d50c37cd7c549e8ac54ca03f11",
  "product_patch_id": "a86d26708c001792f5a767aab4300cb3be9b6d9d",
  "gstack_version": "1.102.2.0",
  "review_depth": {
    "depth": "light",
    "class": "code",
    "runtime_lines": 90,
    "rules": "630fd3101899e28e",
    "base": "0b4f0ceeec19fef62480db6c8eb00c4015380a39",
    "registry": "0b4f0ceeec19fef62480db6c8eb00c4015380a39",
    "gate_scan": {
      "tagged": 0,
      "head": "518975b1699e3a2971581b2140e9024de87c8322"
    },
    "reasons": [
      "runtime=90"
    ],
    "risk": [],
    "mode": "panel"
  },
  "pregate": "requires-remote cleared @e65c33e3b173 (8 checks, current for 518975b1699e)",
  "requires_remote": [
    "free-tests.yml/cso-macos-launcher: https://github.com/garrytan/gstack/actions/runs/44999092743/attempts/1",
    "free-tests.yml/macos-named-regressions: https://github.com/garrytan/gstack/actions/runs/44999092743/attempts/1",
    "windows-setup-e2e.yml/windows-setup: https://github.com/garrytan/gstack/actions/runs/44994919277/attempts/1",
    "windows-smoke.yml/windows-smoke: https://github.com/garrytan/gstack/actions/runs/44994919240/attempts/1",
    "pregate.json/remote_gate: remote-gate tree=e65c33e3b173 tests=38827 skipped=104 runs=44999092743/1 profiles=ci-reuse/free-tests heads=518975b1699e verified=2026-11-22T07:55:52.155Z"
  ],
  "issues": {
    "fixes": [],
    "refs": [
      4164,
      4288,
      4308,
      4324,
      4386,
      4420,
      4548,
      4682
    ],
    "flakes": []
  },
  "docs": {
    "status": "updated",
    "scope": "docs/, README.md, AGENTS.md, CLAUDE.md, CONTRIBUTING.md, ARCHITECTURE.md against commits c2b4f0d..cf86d3d (30 files)"
  },
  "review_loop": {
    "passes": 2,
    "blocking_found": 3,
    "deferred": 1,
    "noted": 9,
    "fixed": 2,
    "scope": "frozen",
    "fix_checks": 1,
    "rounds": 2,
    "dispatches": {
      "specialist": 1,
      "red-team": 1
    }
  },
  "gate_dispositions": []
}

…tor fixes from outside reports

TypeScript hooks start on Windows when Git Bash leaves a path unconverted
(#4386); setup --status passes on prefix installs (#4164) and names commands
that clear its rows (#4420); setup's bun installs run under umask 022 (#4288);
disabling open-gstack-browser removes connect-chrome (#4308); gstack-doctor
skips gstack's own CLAUDE.md (#4324); harness registrations honor
disabled_skills (#4548).

Co-authored-by: Arnuv <[email protected]>
Co-authored-by: Mahmoud ElNeMR <[email protected]>
Co-authored-by: Yuan S. <[email protected]>
Co-authored-by: Alexander William Haire <[email protected]>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@trunk-io

trunk-io Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

😎 This pull request was merged.

garrytan and others added 2 commits November 22, 2026 06:19
… read hook paths literally

Review fixes for the second-model review on PR #4682: the connect-chrome alias cleanup now removes only the generated SKILL.md (an edited one is backed up, other files stay), and gstack-hook-check turns off globbing while it hands hook paths to cygpath and Bun.

Review-Finding: p1v/outside-voice#1 reader=outside-voice
Review-Finding: p1v/outside-voice#3 reader=outside-voice
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant