Skip to content

fix(deploy): a cut-off probe answer is never "ok", and the tip-check reads ask gh for only what they use - #4711

Merged
joelteply merged 1 commit into
canaryfrom
fix/probe-truncation-and-tip-checks
Oct 4, 2026
Merged

joelteply merged 1 commit into
canaryfrom
fix/probe-truncation-and-tip-checks

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

The deploy tracker's workflow-runs read for a canary tip is 90 KB; the bounded probe keeps 64 KB
and probe() dropped Captured's truncated flag, so the cut JSON came back "ok", failed to parse,
and parse_tip_checks fell back to counting every check. #4706's core-binaries exclusion never
applied: every node's deploy waited on the 44-73 min macOS legs (the 5090 on b6ddc0d,
2026-10-04: total 10, excluded 0, filtered false, runs_read ok).

  • bounded_command: Probed::Truncated, outcome "truncated", never stdout_if_ok. Every caller
    of probe now sees an incomplete answer as one; the existing large-output test asserts it.
  • deploy_tracker: both gh reads project with --jq to the fields parse_tip_checks reads
    (check-runs 31 KB -> 1.2 KB, runs 90 KB -> 0.6 KB on b6ddc0d).

Validation:

  • cargo check -p continuum-core --lib is clean.
  • The projected gh calls were run on the 5090 against b6ddc0d: 606 B and 1200 B.
  • The extended unix test in bounded_command (the existing large-output test) asserts Probed::Truncated.

🤖 Generated with Claude Code

…reads ask gh for only what they use

The deploy tracker's workflow-runs read for a canary tip is 90 KB; the bounded probe keeps 64 KB
and `probe()` dropped `Captured`'s truncated flag, so the cut JSON came back "ok", failed to parse,
and parse_tip_checks fell back to counting every check. #4706's core-binaries exclusion never
applied: every node's deploy waited on the 44-73 min macOS legs (the 5090 on b6ddc0d,
2026-10-04: total 10, excluded 0, filtered false, runs_read ok).

- bounded_command: `Probed::Truncated`, outcome "truncated", never `stdout_if_ok`. Every caller
  of `probe` now sees an incomplete answer as one; the existing large-output test asserts it.
- deploy_tracker: both gh reads project with --jq to the fields parse_tip_checks reads
  (check-runs 31 KB -> 1.2 KB, runs 90 KB -> 0.6 KB on b6ddc0d).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@joelteply

Copy link
Copy Markdown
Contributor Author

APPROVED at a1ee78b on green (Cormac), conditional on cargo test -p continuum-core --lib and the windows-msvc check. Both are pending as I write this. A new Probed variant breaks any exhaustive match elsewhere, and only the compile tells us.

Why it's right:

  • Root cause. A capture cut at 64 KB came back as Exited { success: true }, so half a JSON body parsed as "no runs" and parse_tip_checks silently fell back to counting every check. That's one value with two meanings ("ok" meaning both "here's the answer" and "here's the first 64 KB of it"). Probed::Truncated, with stdout_if_ok() == None, gives it its own name. The regression test pins it with a real 300 KB child, not a fixture.
  • The --jq projections keep exactly the fields parse_tip_checks reads: check_runs[].{name,status,conclusion,check_suite.id} and workflow_runs[].{event,path,check_suite_id}. 90 KB → 0.6 KB means the body can't grow back over the limit as checks are added.
  • Other probe callers: nvidia-smi, sysctl, vulkaninfo --summary, git rev-parse, launchctl. All have small output. For any of them, a truncated answer now reads as "no answer" instead of a partial one, which is the safe direction.

Two non-blocking notes:

  1. per_page=100 on check-runs is a ceiling of its own. Canary has 10 checks today; past 100, the read would quietly miss checks without truncating. Worth a probe field check_runs_total (gh returns total_count) compared against the count read, so that miss is visible too.
  2. A truncated failure (non-zero exit) still maps to Exited { success: false } = "absent". That's fine for every current caller, but the doc on Truncated could say it is only for a successful exit.

This one likely affected every node: every deploy waited on the 44-73 min macOS core-binaries legs. Thanks for chasing it to the byte.

@joelteply
joelteply merged commit cc2472e into canary Oct 4, 2026
7 checks passed
@joelteply
joelteply deleted the fix/probe-truncation-and-tip-checks branch October 4, 2026 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant