Skip to content

Commit ba62fe2

Browse files
committed
ci(windows): swap install smoke for ls smoke — dist gap upstream
The "install hyperfine" smoke step on \`test-windows\` failed with \`Error: CmdNotFound("hyperfine")\`. Investigation: hyperfine has no Windows build in \`dist.pkgx.dev\`. Exhaustive probe of all 842 top- level prefixes in the bucket found zero packages with a \`windows/\` subdir — pkgx-on-Windows can pull \`pkgx.exe\` itself but no other package. \`pkgm install\` on Windows is blocked on upstream shipping Windows artifacts, independent of pkgm's port. Drop the install step (it can't pass), keep the \`--version\` floor, and add a \`pkgm ls\` smoke that exercises install_prefix() (now %LOCALAPPDATA%\pkgm) and the new Windows candidate-paths branch in ls() without depending on a real install. Job no longer needs \`continue-on-error: true\` — both remaining steps are deterministically achievable on Windows today.
1 parent fcbba47 commit ba62fe2

1 file changed

Lines changed: 18 additions & 18 deletions

File tree

.github/workflows/ci.yml

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -109,13 +109,18 @@ jobs:
109109
./pkgm.ts i spotify_player
110110
spotify_player --version
111111
112-
# Scaffolding-pass smoke test for the Windows port. Uses an explicit
112+
# Scaffolding-pass smoke for the Windows port. Uses an explicit
113113
# `pkgx deno^2.1 run` invocation because the kernel doesn't interpret
114114
# `#!/usr/bin/env -S pkgx …` shebangs on Windows; a `pkgm.cmd` wrapper
115115
# that papers over this belongs in pkgxdev/setup's installer.ps1, not
116-
# here. continue-on-error: true while the port is in progress.
116+
# here.
117+
#
118+
# End-to-end install can't be exercised yet: a probe of all 842
119+
# top-level prefixes in dist.pkgx.dev (the bucket pkgx pulls from)
120+
# finds zero packages with a `windows/` subdir. pkgm install is
121+
# blocked on upstream shipping Windows artifacts; we test what we
122+
# can — that pkgm runs at all on Windows.
117123
test-windows:
118-
continue-on-error: true
119124
runs-on: windows-latest
120125
defaults:
121126
run:
@@ -125,9 +130,9 @@ jobs:
125130
- uses: pkgxdev/setup@v4
126131

127132
- name: smoke - pkgm --version
128-
# Verifies the absolute floor: pkgx is on PATH, deno can run
129-
# the script, libpkgx imports resolve on Windows, parseArgs +
130-
# the `version` arm exit 0. No filesystem touching yet.
133+
# Verifies the floor: pkgx.exe is on PATH, deno can run the
134+
# script, libpkgx imports resolve on Windows, parseArgs + the
135+
# version arm exit 0. No filesystem touching yet.
131136
run: |
132137
$denoArgs = @(
133138
'deno^2.1', 'run', '--ext=ts',
@@ -139,27 +144,22 @@ jobs:
139144
pkgx @denoArgs
140145
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
141146
142-
- name: smoke - install hyperfine
143-
# Exercises the install path end-to-end on Windows. Expected to
144-
# fail at one of: pantry resolution (if no Windows build), the
145-
# hardlink-fallback path in symlink_with_overwrite, or the .cmd
146-
# emission step. Failure mode is the discovery signal for the
147-
# next iteration.
147+
- name: smoke - pkgm ls on a fresh runner
148+
# Exercises install_prefix() (now %LOCALAPPDATA%\pkgm on
149+
# Windows) and the ls() candidate-paths branch. Fresh runner
150+
# → no installed pkgs → empty output, exit 0. Catches regressions
151+
# in the path-resolution layer without depending on
152+
# dist.pkgx.dev having Windows builds.
148153
run: |
149154
$denoArgs = @(
150155
'deno^2.1', 'run', '--ext=ts',
151156
'--allow-sys=uid', '--allow-run', '--allow-env',
152157
'--allow-read', '--allow-write', '--allow-ffi',
153158
'--allow-net=dist.pkgx.dev',
154-
'./pkgm.ts', 'i', 'hyperfine'
159+
'./pkgm.ts', 'ls'
155160
)
156161
pkgx @denoArgs
157162
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
158-
$expected = Join-Path $env:LOCALAPPDATA "pkgm\pkgs\crates.io\hyperfine"
159-
if (!(Test-Path $expected)) {
160-
Write-Error "expected hyperfine cache at $expected"
161-
exit 1
162-
}
163163
164164
# Validates `sudo pkgm install` behaviour fixed in 2b33f20:
165165
# - privilege drop so pkgx cache stays owned by $SUDO_USER, not root

0 commit comments

Comments
 (0)