Skip to content

feat: the scheduled-nightly release driver (release nightly)#63

Merged
Jammy2211 merged 1 commit into
mainfrom
feature/nightly-release-implementation
Jul 9, 2026
Merged

feat: the scheduled-nightly release driver (release nightly)#63
Jammy2211 merged 1 commit into
mainfrom
feature/nightly-release-implementation

Conversation

@Jammy2211

Copy link
Copy Markdown
Contributor

Phase 2 of PyAutoLabs/PyAutoBuild#127 — the scheduled-nightly release driver, implementing the merged design (PyAutoBuild/docs/nightly_release_design.md §3–§6, §10). This is the path the AUTONOMY.md standing grant (2026-07-09) authorises.

What's here

  • agents/conductors/release/nightly.sh — deterministic driver (no LLM in the release gate): kill switch (NIGHTLY_RELEASES, scheduled runs only) → same-day tag guard → activity gate → release-blocker check → the M1–M4 validate choreography (validate.sh Phases A→C, executing the emitted dispatch plans with gh — parameters parsed from the plans, nothing duplicated) → CI snapshot assembly (cloud-safe checks + ingest + state.aggregate()) → the release-ci readiness gate through the vitals faculty (GREEN only; there is no force input) → live dispatch of Build's release.yml → one Slack message per terminal outcome. --no-dispatch gives a strictly read-only gates-only run; NIGHTLY_WINDOW_START overrides the window for verification.
  • activity_gate.py — the unit-tested judgment: 11-repo release-relevant set, pipeline self-commit exclusion (^Release <YYYY.…> message or the pipeline git identity), window verdict + summary.
  • .github/workflows/nightly-release.yml — the 02:00 UTC scheduler (a scheduler, nothing more). dry_run defaults true until the arming checklist flips it; concurrency-guarded so two nights can't race.
  • Routing: pyauto-brain release nightly; consult_vitals_verdict gains --profile passthrough (boundary preserved — only the vitals faculty talks to Heart for the verdict).
  • tests/test_activity_gate.py — first tests/ in this repo; pins the self-commit exclusion contract so release.yml identity/message drift fails a test instead of re-counting releases as activity.

The activity-window anchor is the repo Actions variable NIGHTLY_LAST_WINDOW_END, advancing only on shipped / empty-skip outcomes — dry-runs and stops never swallow unshipped activity.

Validation

  • pytest tests/ — 8 passed.
  • bash -n on every touched script; workflow YAML parses.
  • Live read-only run (release nightly --no-dispatch): 24h window correctly quiet (today's merges were organism repos, outside the release-relevant set); 8-day window found activity in all 11 repos; after labelling #126 the blocker gate stopped with exit 2 and the paging message.

API Changes

None (no Python library surface) — new conductor subcommand release nightly.

Scripts Changed

  • agents/conductors/release/nightly.sh, activity_gate.py (new), release.sh (routing), agents/_common.sh (--profile), bin/pyauto-brain (help), .github/workflows/nightly-release.yml (new), tests/test_activity_gate.py (new).

Nothing is armed by merging this: the cron fires but exits at the kill switch on scheduled runs, and dry_run defaults true. Arming is the human checklist (design §9). Companion PRs: PyAutoBuild (cron removal), PyAutoHeart (release-ci profile), PyAutoMind#43 (digest watchdog) — links in a comment.

🤖 Generated with Claude Code

Phase 2 of PyAutoLabs/PyAutoBuild#127 — implements the merged design
(PyAutoBuild docs/nightly_release_design.md §3-§6, §10): nightly.sh
sequences kill switch → same-day guard → activity gate → release-blocker
check → the M1-M4 validate choreography (executing validate.sh's emitted
dispatch plans with gh, available in CI unlike the MCP-only sessions the
plans were written for) → the release-ci readiness gate (GREEN only, no
force input) → live dispatch of Build's release.yml, one Slack outcome
per terminal path. activity_gate.py holds the unit-tested window /
self-commit judgment; nightly-release.yml is the 02:00 UTC scheduler
(dry_run defaults true until the arming checklist flips it);
consult_vitals_verdict gains --profile passthrough; routed as
`pyauto-brain release nightly`.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@Jammy2211

Copy link
Copy Markdown
Contributor Author

Phase-2 PR set for PyAutoLabs/PyAutoBuild#127: #63 (driver) · PyAutoLabs/PyAutoBuild#129 (cron removal) · PyAutoLabs/PyAutoHeart#47 (release-ci profile) · PyAutoLabs/PyAutoMind#43 (digest watchdog). Merge Brain and Build the same day (Build-first leaves no scheduled path; Brain-first double-schedules nothing — the driver dispatches, the old cron rehearses — but same-day is tidiest); Heart and Mind are independent.

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.

1 participant