Skip to content

fix(release): publish a release only after its images #7444

Done

Description

@dan-petty

Problem

.github/workflows/release.yml makes the tag at once (force-tag-creation: true) and a draft release. The job assets publishes the draft (gh release edit "$TAG" --draft=false) after it attaches the files, but it needs only release-please, not the image jobs (image, devcontainer-image, devcontainer). So a release can be public before its images exist.

Consumers that pin a release see it too early: dan-petty/homelab#572 (2026-11-27) moved the git pins of devops-cli to v0.226.1 while the images of v0.226.1 were not yet in GHCR, and make k8s-parity failed (dan-petty/homelab#576).

Owner question, 2026-11-27: "should the release images be pushed before the release is published on github?" Yes: publish last, after each artifact that the release names exists.

Change

  • The job that publishes the draft needs each image job of the release and runs only when all succeed. A failed image job leaves the release a draft, and "Re-run failed jobs" publishes it (as assets does today).
  • Correct docs/RELEASE_CYCLE.md and the comment of release.yml.

Done when

  • The published_at of a release is later than the push of each of its images.
  • A release whose image job fails stays a draft.

Proposed design

Problem statement

The release workflow publishes the draft release before its image jobs finish. A consumer can pin a release whose images are not in GHCR yet. The change makes publication wait for every image job, and a failed image job leaves the release a draft.

Acceptance criteria

Requirement: Publish waits for image jobs

The assets job SHALL list release-please, image, devcontainer-image and devcontainer in its needs.

Scenario: Workflow dependency check

  • WHEN a maintainer runs uv run devops ci --check --only actionlint,zizmor on the change
  • THEN actionlint and zizmor pass with no error in .github/workflows/release.yml.

Requirement: Failed image keeps the release a draft

The workflow MUST publish the draft release only after every image job of the release succeeds.

Scenario: Image job failure

  • WHEN an image job of a release run fails
  • THEN the assets job does not run and the release remains a draft.

Requirement: Release documentation states the order

docs/RELEASE_CYCLE.md and the comment of .github/workflows/release.yml MUST state that publication waits for each image job.

Scenario: Documentation check

  • WHEN a maintainer runs uv run devops ci --check --only docs on the change
  • THEN the docs check passes with no error.

Existing Tool Considered

No alternatives check has run. No open, maintained tool or library covers the ordering of jobs in this release workflow. GitHub Actions needs covers the need. The change edits YAML and documentation and builds no code, so it has no build cost.

Key questions

  • Which jobs must the publish job need?: assets must need release-please, image, devcontainer-image and devcontainer. devcontainer already needs devcontainer-image and devcontainer-smoke, so the smoke test also gates publication. (best practice) [sources: .github/workflows/release.yml:98, .github/workflows/release.yml]
    • Rejected: Need only the final devcontainer job. It hides the direct gate on the image build and does not follow the issue text.
    • Chosen: Need release-please and each named image job. It follows the issue and makes every image gate explicit.
  • Should the workflow use default success behavior or always()?: Use default success behavior. A failed image job skips assets, so the release stays a draft. Do not add always(). (best practice) [sources: .github/workflows/release.yml:98]
    • Chosen: Default needs success. A failed dependency skips the publish job, which keeps the release a draft.
    • Rejected: if: always(). It would publish after a failed image job and break the requirement.
  • Should the publish job keep the name assets?: Keep assets. It already uploads the packages and publishes the draft, and a rename adds churn with no behavior change. (best practice) [sources: .github/workflows/release.yml:98]
    • Chosen: Keep assets. The job already does the publication step.
    • Rejected: Rename to publish. The rename changes references and adds no value.
  • Does "Re-run failed jobs" publish the release after a failed image job?: Yes. A re-run of the failed jobs also runs the dependent assets job when the failed job succeeds. The release then publishes. [sources: .github/workflows/release.yml:7]

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

None.

Activity

  1. added
    type/bug
    scope/release
    source/agent
    status/new
    effort/low
    on Nov 27, 2026
  2. dan-petty commented on Nov 27, 2026

    @dan-petty
    OwnerAuthor
    • Priority: A consumer pinned a release whose images were absent, causing a downstream job failure.
    • Related: fix(ci): release upload fails on immutable releases #7328, which asks for a different change. Both fix the order of publishing versus uploading in release.yml, but #7328 fixes immutable-release upload failures while the candidate fixes missing images at publish time.
  3. added
    value/high
    priority/p1-high
    on Nov 27, 2026
  4. devops-cli-service commented on Nov 27, 2026

    @devops-cli-service
    Contributor

    Next step: the alternatives check records a verdict. See the section Proposed design of the body.

  5. added
    owner/agent
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 27, 2026
  6. removed
    status/in-review
    owner/agent
    on Nov 27, 2026
  7. dan-petty commented on Nov 27, 2026

    @dan-petty
    OwnerAuthor

    Live proof on the first release after #7463, v0.229.1 (run 46060500535): the release was created at 19:59:28Z and published at 20:06:57Z. Each image job ended before that: MCP Server Attest & Tag 20:03:08Z, Build DevContainer Image 20:03:16Z, Service Attest & Tag 20:03:46Z, UV Seed Attest & Tag 20:04:51Z, Smoke-Test DevContainer Image 20:05:47Z, Attest & Tag DevContainer Image 20:06:14Z, Runner Attest & Tag 20:06:33Z. Upload Release Assets ended at 20:06:59Z. So published_at is later than the tag of each image, the "Done when" of this issue.

  8. devops-cli-service commented on Nov 27, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-27 20:34 UTC

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/lowpriority/p1-highscope/releasesource/agenttype/bugvalue/high

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions