Skip to content

Move the deploy pipeline's multi-line steps into tested scripts - #3896

Merged
anth-volk merged 2 commits into
masterfrom
ci-scripts-deploy
Oct 14, 2026
Merged

anth-volk merged 2 commits into
masterfrom
ci-scripts-deploy

Conversation

@anth-volk

Copy link
Copy Markdown
Collaborator

Fixes #3894

Summary

Phase 1 step 1.7, part 2: the production deploy pipeline (push.yml). Stacked on the part 1 PR.

The seven remaining multi-line run: blocks become single-line steps:

Step(s) Now runs Notes
Build changelog build_changelog.sh towncrier for the pyproject.toml version; fails clearly if the version is missing
Run release tests run_release_tests.sh make test with the same env -u list of deployment settings removed
Compute Cloud Run staging/candidate metadata compute_cloud_run_metadata.sh <prefix> the same image_tag/revision_tag outputs (stg, stage3-prod)
Restore previous Cloud Run staging/production revision restore_cloud_run_revision.sh <readiness-url> rolls back, then health-checks; stops if the rollback fails
Install release test dependencies two steps apt-get update now has its own step

Every if:, env: and output name is unchanged. The multi-line baseline is now empty, so api.ci.multiline-run-is-script moves to enforced. Every workflow run: step in this repository is now a single line of code.

Updated existing tests: they asserted the old inline text, and keep the same intent and ordering:

  • test_cloud_run_deploy_scripts.py: the release-test -u list and the "stage3-prod" tag.
  • test_alembic_workflows.py: uv lock runs before the changelog build, and release tests run before deploy.
  • test_app_engine_decommission.py: release tests run before deploy.

Testing

  • New tests/unit/test_deploy_pipeline_scripts.py: 13 tests using fake towncrier, make and helper scripts. They assert exact arguments, outputs and exit codes, including failure paths.
  • Full API unit suite (pytest tests/unit): 2,316 passed.
  • python scripts/run_quality_guards.py: all three guards pass. guard --base-ref ci-scripts-exceptions passes.
  • actionlint, ruff format/ruff check and shellcheck are clean.

🤖 Generated with Claude Code

@codecov

codecov Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.58%. Comparing base (bb03a74) to head (0fe9228).

Additional details and impacted files
@@             Coverage Diff             @@
##           master    #3896       +/-   ##
===========================================
+ Coverage   45.25%   87.58%   +42.33%     
===========================================
  Files         183      198       +15     
  Lines       11085    12223     +1138     
  Branches     1907     2161      +254     
===========================================
+ Hits         5016    10706     +5690     
+ Misses       5647      921     -4726     
- Partials      422      596      +174     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@anth-volk
anth-volk removed this pull request from stack #3888 October 13, 2026 19:26
@anth-volk
anth-volk added this pull request to stack #3917 October 13, 2026 19:26
@anth-volk
anth-volk force-pushed the ci-scripts-deploy branch 2 times, most recently from 87f7783 to c139fb6 Compare October 14, 2026 16:59
@anth-volk
anth-volk force-pushed the ci-scripts-deploy branch 4 times, most recently from 151b2fb to 9ef5bb6 Compare October 14, 2026 21:13
Base automatically changed from ci-scripts-exceptions to master October 14, 2026 21:52
anth-volk and others added 2 commits October 15, 2026 02:05
Seven run: blocks in the deploy pipeline become single-line steps:
- build_changelog.sh: towncrier build for the pyproject version.
- run_release_tests.sh: make test without the deployment settings
  (the same env -u list).
- compute_cloud_run_metadata.sh <prefix>: image_tag and revision_tag
  outputs for staging (stg) and production (stage3-prod).
- restore_cloud_run_revision.sh <readiness-url>: roll back, then check
  health, for staging and production.
- The release Redis install splits apt-get update into its own step.

Every if:, env: and output name is unchanged. New tests run each script
with fake commands; existing workflow-text assertions now check the
scripts instead, with the same intent and ordering.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The multi-line baseline is empty, so the rule moves from ratcheted to
enforced: every workflow run: step is now a single line of code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@anth-volk
anth-volk marked this pull request as ready for review October 14, 2026 22:29
@anth-volk
anth-volk requested a review from a team as a code owner October 14, 2026 22:29
@anth-volk
anth-volk merged commit e45cde2 into master Oct 14, 2026
15 checks passed
@anth-volk
anth-volk deleted the ci-scripts-deploy branch October 14, 2026 22:29

This branch was successfully deployed

1 active deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Move the deploy pipeline's multi-line steps into tested scripts

1 participant