Skip to content

test/ci(windows): Windows-safe engine tests + functional Windows CI leg (#209)#211

Merged
hartsock merged 3 commits into
mainfrom
test/windows-verification
Jul 6, 2026
Merged

test/ci(windows): Windows-safe engine tests + functional Windows CI leg (#209)#211
hartsock merged 3 commits into
mainfrom
test/windows-verification

Conversation

@hartsock

@hartsock hartsock commented Jul 6, 2026

Copy link
Copy Markdown
Member

Lands the Windows verification work from #209 (all green on Windows 11 / rustc 1.93): the brush engine + carried-coreutils are Windows-safe (SystemRoot seed for confined children; shell-quoted paths — the W4 fix from #210), and the Windows CI job now RUNS them (not just compiles). Root cause of the one W4 failure was test path-quoting, not the dispatch machinery — carried coreutils work on Windows. Linux stays green. Feeds rc.2.

Refs #209, #210. risk:low (tests + a Windows CI step).

hartsock and others added 3 commits July 6, 2026 15:21
…s-safe

Prep for a Windows functional-validation run (the engines are compiled on the
Windows CI job but never executed there; validated so far only on macOS/Linux).

- brush engine: under `do_not_inherit_env(true)` a spawned child on Windows needs
  the OS-minimal vars (`SystemRoot`, …) or `CreateProcess`/CRT init fails to start
  it at all. Seed them on Windows (not secrets — every process needs them) so
  external commands and the carried-coreutils re-exec are runnable under
  confinement. No-op on unix.
- carried_coreutils test: replace `env_clear()` with a `scrubbed()` helper that
  drops `PATH` (so only carried tools satisfy a bare `ls`/`cat`) but keeps the
  Windows OS-minimal env, so the harness process can start on Windows.

Unix behavior unchanged (the `#[cfg(windows)]` blocks compile out); Linux
brush_real 3/3 + carried_coreutils 2/2 still green, clippy -D warnings clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HRv5vteHCw4jUayHGL5esx
)

Windows verification of 0.7.0-rc.1 found carried_ls/carried_cat failing
on Windows: the command strings were built with a raw, unquoted path
(e.g. `cat C:\Users\...\hello.txt`) fed straight into brush's POSIX-style
parser, which treats an unescaped `\` as an escape character and silently
collapses the path (`C:\Users\...` -> `C:Users...`), so the file can never
resolve. The carried-coreutils re-exec/dispatch machinery itself was never
broken -- confirmed by hand that the same command succeeds once the path
is shell-quoted.

Mirrors agent-bridle-jaild::vm::shell_quote's single-quote + embedded-quote
escaping.

Co-authored-by: Shawn Hartsock <hartsock@users.noreply.github.com>
)

The Windows CI job compiled the brush engine + carried coreutils (via
--all-features clippy) but never executed them — they were validated only on
macOS/Linux until the #209 Windows pass. Add a step that RUNS
brush_real + carried_coreutils with `--features brush,carried-coreutils` on
windows-latest, so the in-process brush engine and the carried-coreutils
dispatch/re-exec are permanently gated on Windows. Mirrored in `just
check-windows` (hook parity).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HRv5vteHCw4jUayHGL5esx
@hartsock hartsock merged commit a46971d into main Jul 6, 2026
10 checks passed
@hartsock hartsock deleted the test/windows-verification branch July 6, 2026 20:15
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