You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
pkarr-worker(deploy): workerExists() treats any cf error as 'worker does not exist' — a transient/auth probe failure silently reroutes a standard deploy into the bootstrap cf deploy path #4865
pkgs/pkarr-worker/deploy.mjs's workerExists() treats any failure of cf workers get pkarr as "the Worker does not exist":
// current main (eefeab5af), pkgs/pkarr-worker/deploy.mjs:130-142functionworkerExists(){try{execFileSync("cf",["-q","workers","get",WORKER],{ ... });returntrue;}catch{returnfalse;}}
and the caller (deploy.mjs:85) routes on that boolean:
Verified on current main eefeab5af648ac612899c65a4c575c20808ef0e1 via two independent contents-API reads: the catch-all catch { return false; } is unchanged, and stderr is piped away (stdio: ["inherit", "pipe", "pipe"]), so nothing distinguishes a not-found response from an auth failure, a network error, a rate limit, or a broken cf install.
Why it matters
When the Worker does exist but the probe fails for any transient reason (expired/insufficient token, Cloudflare API blip, network error), the script silently takes the bootstrap path and runs cf deploy, which uploads and deploys at 100% immediately — bypassing the deployment standard's versions flow (versions create → ?deployable=true pre-check → deployments create) that PR #3234 established and PRs #3242/#3244 hardened. The run then reports success as a "bootstrap", so the misroute is invisible in the output an operator reads. A probe error should be a stop, not a silent change of deploy mechanism.
Related but distinct from the already-filed deploy.mjs findings #3252 (--dry-run ignored on the --deploy-version path) and #3264 (unrecognized arguments silently ignored) — this one is the existence probe's error classification.
Acceptance criteria
workerExists() (or its replacement) returns "does not exist" only for the actual not-found response from cf workers get; any other failure (non-not-found exit, spawn error) aborts the deploy with the cf error visible.
The bootstrap cf deploy path is unreachable when the existence probe errored for a reason other than not-found.
A probe/dry-run demonstration: simulated not-found → bootstrap path chosen; simulated auth/network failure → deploy refuses before uploading anything.
Expectation: effort/s — done when only a genuine not-found response routes to the bootstrap cf deploy path and any other probe failure aborts the deploy.
agent-note:v1
state: reviewed (coverage loop-back)
Coverage pass 2026-11-03, loop-back review: this issue was re-reviewed (drift / overlap / already-handled / stale / blockers / ordering) so every open issue in the four repos is reviewed and in the system. Verdict: still live; in the system as task 7522 (triage, queued, priority 50) in repo-health-code-pilot. Labels audited and synced. If it is already handled at current main, its triage closes it with evidence; if oversized, the triage files the split; blockers belong on this issue.
Found via: coverage loop-back 2026-11-03
Expectation: effort class s; done = only genuine Worker-not-found routes to bootstrap, other probe failures abort with diagnostics, regression tests pass.
Agent: queue worker (repo-worker-code), OpenChamber scheduled lane
Session / ID: task 9735 · lane 9aca43b4-5439-4939-9f71-323f5d32521b
Found via: queue claim
Task: Implement the bounded workerExists() failure classification and regression tests from task 9735; resuming directly after atomic claim of the expired handoff.
Expectation: only genuine Worker-not-found selects bootstrap; other probe failures abort before upload/deploy with useful diagnostics.
Picked up by repo-worker-code-f — working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live while repo-worker-code-f posts progress markers; after 30 minutes of silence any other worker may pick this up.)
🤖 Agent note · fixed — PR #6811 open, remainder: merge on green CI
Agent: queue worker lane F (repo-worker-code-f), fallback claim (queue backend down, code#6619)
Fix: PR fix(pkarr-worker): existence probe aborts on non-not-found cf failures (#4865) #6811, branch queue/4865-pkarr-worker-exists-probe. New pkgs/pkarr-worker/deploy-probe.mjs: probeWorkerExists returns "does not exist" only for the genuine not-found response (API code 10007 / workers.api.error.not_found / rendered script-not-found; deliberately narrow matcher); any other probe failure (auth, network, spawn) aborts the deploy before any upload with the cf error visible. deploy.mjs delegates to it; the new-Worker bootstrap (PR fix(pkarr): bootstrap a brand-new Worker via cf deploy (#1829) #3241) is unchanged. 7 vitest cases in test/deploy-probe.test.ts + deploy-probe.d.mts.
Verification: direct node probe on the laptop — exists → true, 10007 → false, auth failure → throws with cf text visible, ENOENT → throws; node --check clean on both scripts. The vitest suite runs in CI (workers-pool suite needs the package npm ci).
Released by repo-worker-code-f (outcome: free). Fixed in PR #6811 (deploy-probe.mjs: not-found-only classification, abort with cf error visible on any other probe failure; 7 vitest cases; node probe verified). REMAINS: merge PR #6811 when CI green (disposition Codex findings first), then close #4865.
Note: this issue carries queue/queued but has NO live queue task in repo-health-code-pilot (verified against the live Turso tasks table this run), so the monitor could not bind/park a task on the canonical PR — the binding gap is recorded here and in the run tracker.
Activity
dezren39 commentedon Nov 3, 2026
🤖 Agent note · filed
dezren39 commentedon Nov 3, 2026
agent-note:v1
state: reviewed (coverage loop-back)
Coverage pass 2026-11-03, loop-back review: this issue was re-reviewed (drift / overlap / already-handled / stale / blockers / ordering) so every open issue in the four repos is reviewed and in the system. Verdict: still live; in the system as task 7522 (triage, queued, priority 50) in repo-health-code-pilot. Labels audited and synced. If it is already handled at current main, its triage closes it with evidence; if oversized, the triage files the split; blockers belong on this issue.
Found via: coverage loop-back 2026-11-03
dezren39 commentedon Nov 4, 2026
🤖 Agent note · handed off
64 remaining items
dezren39 commentedon Nov 5, 2026
🤖 Agent note · handed off
dezren39 commentedon Nov 5, 2026
🤖 Agent note · picked up
fix(pkarr): stop on worker probe failures (#4865)
developing-today commentedon Nov 7, 2026
Picked up by
repo-worker-code-f— working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live whilerepo-worker-code-fposts progress markers; after 30 minutes of silence any other worker may pick this up.)developing-today commentedon Nov 7, 2026
Progress from
repo-worker-code-f: verified: workerExists catch-all present at deploy.mjs on c3fe40e; fix shape: extract deploy-probe.mjs (not-found-only classification, abort otherwise) + vitest cases; next: implementdeveloping-today commentedon Nov 7, 2026
🤖 Agent note · fixed — PR #6811 open, remainder: merge on green CI
queue/4865-pkarr-worker-exists-probe. Newpkgs/pkarr-worker/deploy-probe.mjs:probeWorkerExistsreturns "does not exist" only for the genuine not-found response (API code 10007 /workers.api.error.not_found/ rendered script-not-found; deliberately narrow matcher); any other probe failure (auth, network, spawn) aborts the deploy before any upload with the cf error visible.deploy.mjsdelegates to it; the new-Worker bootstrap (PR fix(pkarr): bootstrap a brand-new Worker via cf deploy (#1829) #3241) is unchanged. 7 vitest cases intest/deploy-probe.test.ts+deploy-probe.d.mts.node --checkclean on both scripts. The vitest suite runs in CI (workers-pool suite needs the package npm ci).free, notdone): PR fix(pkarr-worker): existence probe aborts on non-not-found cf failures (#4865) #6811's CI had not run within the poll window (fleet CI backlogged tonight). Next worker: check PR fix(pkarr-worker): existence probe aborts on non-not-found cf failures (#4865) #6811 (incl. Codex findings — disposition any before merging); if green, merge and close pkarr-worker(deploy): workerExists() treats any cf error as 'worker does not exist' — a transient/auth probe failure silently reroutes a standard deploy into the bootstrap cf deploy path #4865. Do not redo the fix.developing-today commentedon Nov 7, 2026
Released by
repo-worker-code-f(outcome: free). Fixed in PR #6811 (deploy-probe.mjs: not-found-only classification, abort with cf error visible on any other probe failure; 7 vitest cases; node probe verified). REMAINS: merge PR #6811 when CI green (disposition Codex findings first), then close #4865.dezren39 commentedon Nov 7, 2026
🤖 Agent note · handed off
Merge pull request #6811 from developing-today/queue/4865-pkarr-worke…