Skip to content

cd: publish candidate release as draft for immutable releases - #3066

Open
Sauvi72 wants to merge 1 commit into
theupdateframework:developfrom
Sauvi72:fix/2920-immutable-releases
Open

Sauvi72 wants to merge 1 commit into
theupdateframework:developfrom
Sauvi72:fix/2920-immutable-releases

Conversation

@Sauvi72

@Sauvi72 Sauvi72 commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Summary

Updates .github/workflows/cd.yml so the candidate release is created as a draft, all release assets are awaited while still in draft, and the release is finalized (draft: false) after environment approval and PyPI publishing — making the workflow compatible with GitHub's Immutable Releases setting.

Changes

  • .github/workflows/cd.yml:
    • Set draft: true in github.rest.repos.createRelease during candidate_release.
    • Replaced forEach with for (const file of fs.readdirSync('dist/')) and awaited github.rest.repos.uploadReleaseAsset so every asset upload completes (and upload failures fail the job) before release runs.
    • awaited github.rest.repos.updateRelease with draft: false in release after the release environment approval and PyPI publish step.

Verification

  • Parsed .github/workflows/cd.yml with yaml.safe_load — valid YAML.
  • Syntax-checked both actions/github-script JS blocks with node --input-type=module --check — passed.
  • Ran .venv/bin/python -m unittest discover -s tests — 208 tests passed in 1.395s.

Closes #2920

Signed-off-by: saurav kumar <krsauvi@gmail.com>
@Sauvi72
Sauvi72 requested a review from a team as a code owner November 26, 2026 09:32

This branch has not been deployed

No deployments
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.

Use Immutable Releases

1 participant