Repository navigation
fix(renderer): move the deploy's render probes into a script - #12497
Merged
Merged
Conversation
Cloud Build refused the renderer deploy for PB-2a (#12490) before its first step ran: "invalid build: invalid .steps field: build step 7 arg 1 too long (max: 10000)". The inline smoke step had grown to 11,347 characters with the plotly probe (build dc1cf3ae, 2026-11-01); the agents service deployed and the renderer kept its PB-1 revision. - agents/renderer/deploy_smoke.sh holds the render probes (matplotlib, Makie, Chart.js, plotly, data run), unchanged except for Cloud Build's `$$` escapes; the smoke step keeps the candidate, IAM and /status checks and calls the script with the token in the environment (3,606 characters). - tests/unit/test_cloudbuild_configs.py holds every step argument of every Cloud Build config under 10,000 characters (it fails on main's config). - test_image.py reads the probes from the script and runs it end to end against a fake curl: all five probes pass with the token, and a plotly render that fails twice refuses the promotion. - ci-tests.yml runs the unit tests when a Cloud Build config or the smoke script changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
…utable From the Gemini Flash pre-PR check. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
…s the smoke script From Copilot's review of #12497. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The test’s shallow discovery pattern can miss deeply nested Cloud Build configurations, leaving the advertised coverage incomplete.
1 open issue
What changed in this PR
This pull request fixes the renderer deployment failure caused by Cloud Build’s 10,000-character step-argument limit by moving the deploy smoke probes into a standalone script while preserving the existing validation and promotion gates.
Changes:
- Added
agents/renderer/deploy_smoke.shwith matplotlib, Makie, Chart.js, Plotly, and data-run probes. - Updated the renderer Cloud Build configuration to invoke the script with the token supplied through the environment.
- Added smoke-script and Cloud Build argument-limit tests.
- Updated CI path detection, documentation, and the changelog.
| File | Summary | Final review notes |
|---|---|---|
tests/unit/test_cloudbuild_configs.py |
Verifies Cloud Build step arguments remain within platform limits. | Moderate, 2 votes: Make config discovery recursive so nested Cloud Build configurations cannot be omitted from coverage. |
tests/unit/agents/test_image.py |
Tests probe contents, ordering, token forwarding, request construction, and failure handling. | — |
docs/concepts/agent-network.md |
Documents the expanded renderer smoke process and script-based deployment flow. | Nit, 1 vote: Update the renderer section of agents/README.md so it no longer conflicts with the expanded smoke behavior. |
changelog.d/renderer-smoke-script.md |
Records the renderer deployment fix. | Nit, 1 vote: Remove (#12497) from the fragment so release tooling can append the pull request reference. |
agents/renderer/deploy_smoke.sh |
Hosts the renderer deployment smoke probes and retry behavior. | Moderate, 1 vote: Avoid expanding the token into curl arguments; pass the header through a configuration file descriptor to prevent exposure through process arguments. |
agents/renderer/cloudbuild.yaml |
Replaces the oversized inline smoke step with the external script invocation. | — |
.github/workflows/ci-tests.yml |
Runs tests when Cloud Build configurations or the smoke script change. | — |
Review effort: Lite
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
invalid build: invalid .steps field: build step 7 arg 1 too long (max: 10000)(builddc1cf3ae, 2026-11-01). The inlinesmokestep had reached 11,347 characters with the plotly probe; the agents service deployed (it now offers plotly and bokeh to the admin) while the renderer kept its PB-1 revision, without PB-2a's figure-markup checks.agents/renderer/deploy_smoke.sh; only Cloud Build's$$escapes become$(a normalised line diff against the removed inline text is identical). The step keeps the candidate double read, the anonymous-403 check, the token mint and/status, and calls the script with the token in the environment. The step's argument is now 3,606 characters.tests/unit/test_cloudbuild_configs.pykeeps every step argument of every Cloud Build config at or under 10,000 characters (it fails on main's renderer config), andci-tests.ymlruns the unit tests when a Cloud Build config or the script changes.Plan
N/A (incident fix after the PB-2a merge).
Test plan
pytest tests/unit tests/integration -n 4: 25,800 passed, 141 skipped./status, with the token through the environment; the script runs end to end against a fakecurl(all five probes pass and send the token; a plotly render that fails twice exits non-zero and skips the data run); the plotly probe writes a validRenderRequest.step 7 (smoke) arg 1: 11347 characterson main's config.curlrejects unknown flags; the script is executable. Not applied: a 9,000-character margin, becauseapp/cloudbuild.yamlalready has a 9,895-character argument; moving that one is a separate follow-up.deploy-rendererpasses its smoke on Cloud Run (Makie, Chart.js and plotly gates) and promotes; then the site smoke.No live loop exists for Cloud Build configs; the deploy after the merge is the first real run of the script.