ci: fix the two downstream jobs (global-install npm pack, windows-integration open)
These jobs ran for the first time once the Windows matrix hang was fixed: - Global Install: `npm pack` runs the `prepare` script (`husky`), but husky isn't installed in that job (no devDeps) → "husky: not found", exit 127. Guard it: `prepare: husky || true` (husky's recommended pattern for envs without devDeps; still installs hooks for local dev when husky is present). - Windows Integration: `agent-browser open` defaults to auto-connect and looked for an existing Chrome on a debug port, which a fresh CI runner lacks → "Could not connect". A CI smoke test should spawn its own browser: use `--launch`.
This commit is contained in:
@@ -164,7 +164,10 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
$env:PATH = "$pwd\bin;$env:PATH"
|
$env:PATH = "$pwd\bin;$env:PATH"
|
||||||
Write-Host "--- Opening page ---"
|
Write-Host "--- Opening page ---"
|
||||||
bin/agent-browser-win32-x64.exe open https://example.com
|
# --launch: spawn a standalone browser. Without it, `open` defaults to
|
||||||
|
# auto-connect and looks for an existing Chrome on a debug port — which
|
||||||
|
# a fresh CI runner doesn't have, so it errors "Could not connect".
|
||||||
|
bin/agent-browser-win32-x64.exe --launch open https://example.com
|
||||||
if ($LASTEXITCODE -ne 0) { Write-Error "open failed"; exit 1 }
|
if ($LASTEXITCODE -ne 0) { Write-Error "open failed"; exit 1 }
|
||||||
Write-Host "--- Taking snapshot ---"
|
Write-Host "--- Taking snapshot ---"
|
||||||
$snapshot = bin/agent-browser-win32-x64.exe snapshot
|
$snapshot = bin/agent-browser-win32-x64.exe snapshot
|
||||||
|
|||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "agent-browser-stealth",
|
"name": "agent-browser-stealth",
|
||||||
"version": "0.27.0-fork.33",
|
"version": "0.27.0-fork.33",
|
||||||
"description": "Browser automation CLI for AI agents — stealth fork with anti-detection",
|
"description": "Browser automation CLI for AI agents \u2014 stealth fork with anti-detection",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"packageManager": "pnpm@11.1.3",
|
"packageManager": "pnpm@11.1.3",
|
||||||
"files": [
|
"files": [
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
"abs": "bin/agent-browser.js"
|
"abs": "bin/agent-browser.js"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "husky",
|
"prepare": "husky || true",
|
||||||
"version:sync": "node scripts/sync-version.js",
|
"version:sync": "node scripts/sync-version.js",
|
||||||
"version": "npm run version:sync && git add cli/Cargo.toml",
|
"version": "npm run version:sync && git add cli/Cargo.toml",
|
||||||
"build:native": "npm run version:sync && cargo build --release --manifest-path cli/Cargo.toml && node scripts/copy-native.js",
|
"build:native": "npm run version:sync && cargo build --release --manifest-path cli/Cargo.toml && node scripts/copy-native.js",
|
||||||
|
|||||||
Reference in New Issue
Block a user