Skip to content

ci(release): release with release-please and an approval step - #2

Merged
tedi-z merged 1 commit into
mainfrom
ci/release-please
Oct 27, 2026
Merged

tedi-z merged 1 commit into
mainfrom
ci/release-please

Conversation

@tedi-z

@tedi-z tedi-z commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Releases stop being manual. This adapts the zenrows-python-sdk release setup to a plugin with nothing to build or publish.

How a release works

  1. A merged fix(...) or feat(...) PR makes release-please open chore: release X.Y.Z. It bumps plugin.json version and both versions in .github/plugin/marketplace.json.
  2. Merging that PR runs the release job in the release environment, which creates the tag vX.Y.Z and the GitHub release with generated notes.

ci, docs, chore and the other hidden types never open a release PR, so this PR releases nothing.

Differences from python-sdk

  • release-type: simple, no build job, no PyPI steps.
  • No "Run CI on the release PR" step: this repo has no ci.yml.
  • No workflow_dispatch re-run: it only existed to republish to PyPI.
  • skip-changelog: true, as in python-sdk. CHANGELOG.md stays as history; release notes live on the GitHub release.

First release

The tag v0.1.0 (on main's head) has no GitHub release. release-please falls back to the tag, so only commits after it count: the next fix(...) gives 0.1.1.

Before merging (repo settings, admin)

  • Actions: allow GitHub Actions to create and approve pull requests.
  • Environments: create release, deployment branch main only.
  • The ZenRows/prod-approvers team needs write access for CODEOWNERS.

Checks

  • actionlint 1.7.7: clean.
  • release-please v17 source: two extra-files on the same path are merged into one update; a missing tag release falls back to the v0.1.0 tag.

A merged release PR bumps plugin.json and both versions in
.github/plugin/marketplace.json, then a job in the release environment
creates the tag and the GitHub release. Commit hygiene checks PR titles
so release-please can read them.
@AnderRV

AnderRV commented Oct 27, 2026

Copy link
Copy Markdown
Member

The release flow looks right: the version bumps hit the right files, release detection is strict, re-runs are safe and the actions are pinned to SHAs. Two things before merging:

1. There's no approval step until the environment is set up. The release environment doesn't exist on the repo yet. GitHub creates it automatically, with no protection, the first time a job uses it. If this merges first, the first release runs with no approval. The settings list in the description also needs required reviewers (ZenRows/prod-approvers) on release, not just the main-only branch rule: that's what makes it an approval. And main has no branch protection, so CODEOWNERS isn't enforced until code-owner reviews are required.

2. The attribution check misses a Markdown link. generated (with|by) (claude|...) doesn't match Generated by [Claude Code](...) because of the [, which is why this PR's own footer passed. Something like generated (with|by) \[?(claude|chatgpt|copilot|openai|gemini|an? ai)\b closes it. I removed that footer from the description, since it linked a session in a public repo.

@tedi-z
tedi-z merged commit 57f3348 into main Oct 27, 2026
2 checks passed
@AnderRV

AnderRV commented Oct 27, 2026

Copy link
Copy Markdown
Member

Correction to point 1: in iac-bootstrap the release environment has no reviewers by design; it only restricts deploys to main, and merging the release PR is the approval. So no required reviewers. What's needed is the environment declared in iac-bootstrap (environments = ["release"] on copilot-zenrows) before this merges, so the first run doesn't create an unmanaged one, plus the prod-approvers grant if CODEOWNERS stays.

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.

2 participants