Skip to content

ci: split release-please into independent release and PR creation steps#124

Closed
keelerm84 wants to merge 1 commit intomainfrom
devin/1775493715-split-release-please
Closed

ci: split release-please into independent release and PR creation steps#124
keelerm84 wants to merge 1 commit intomainfrom
devin/1775493715-split-release-please

Conversation

@keelerm84
Copy link
Copy Markdown
Member

@keelerm84 keelerm84 commented Apr 6, 2026

Requirements

  • I have added test coverage for new or changed functionality
  • I have followed the repository's pull request submission guidelines
  • I have validated my changes against all supported platform versions

Related issues

Follows the pattern established in ld-relay PR #622 to support GitHub's immutable releases.

Describe the solution you've provided

Splits the single release-please-action invocation into two sequential passes:

  1. First pass (skip-github-pull-request: true): Creates GitHub releases only.
  2. Inline tag creation: If any package was released, checks out the repo and pushes tags for each released package (with idempotent guard via gh api).
  3. Second pass (skip-github-release: true): Runs only when no releases were created; handles PR creation/updates.

This separation is required because release-please checks for an existing tag when deciding whether to open a new release PR. Without the split, release-please could open a duplicate PR immediately after publishing a release because the tag wasn't yet visible.

Since this is a monorepo (4 packages), the tag creation step iterates over all packages, creating tags only for those that were actually released.

Describe alternatives you've considered

A single release-please call with post-processing — rejected because the tag must exist before release-please evaluates PR state, requiring the two-pass approach.

Additional context

Key items for reviewer attention:

  • The second-pass condition uses && (all four != 'true'), meaning PR creation is skipped if any package released. Verify this is correct for a monorepo where only a subset of packages may release in a given run.
  • Tag names are passed through env variables (not inline ${{ }} expansion) to prevent script injection.
  • The outputs block still reads from steps.release.outputs[...] (the first pass). Confirm that skip-github-pull-request: true does not suppress these output fields.
  • Version comment updated from # v4 to # v4.4.0 — the pinned SHA is unchanged.
  • No changes to downstream release jobs (release-server-ai, release-server-ai-langchain, etc.) or the manual-publish job.

Link to Devin session: https://app.devin.ai/sessions/7d5bda4d9dbe4ae0b950b30a50485e60
Requested by: @keelerm84


Note

Medium Risk
Changes the release automation flow to create/push git tags and gate PR creation, which can affect publishing behavior across all packages if the conditions or tag creation logic are wrong.

Overview
Restructures the release-please GitHub Actions workflow to run in two passes: first creating GitHub releases only (skip-github-pull-request: true), then (when any package release is created) checking out the repo and creating/pushing the corresponding git tags with an idempotent existence check via gh api.

Adds a second release-please invocation that runs only when no releases were created to handle release PR creation/updates (skip-github-release: true), preventing PRs from being opened immediately after a release before tags are visible.

Reviewed by Cursor Bugbot for commit 26d0727. Bugbot is set up for automated code reviews on this repo. Configure here.

@keelerm84 keelerm84 requested a review from a team as a code owner April 6, 2026 16:51
@devin-ai-integration
Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 26d0727. Configure here.

steps.release.outputs['packages/sdk/server-ai--release_created'] != 'true' &&
steps.release.outputs['packages/ai-providers/server-ai-langchain--release_created'] != 'true' &&
steps.release.outputs['packages/ai-providers/server-ai-openai--release_created'] != 'true' &&
steps.release.outputs['packages/optimization--release_created'] != 'true'
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Monorepo PR creation skipped on partial release

Medium Severity

The second-pass condition uses && across all four release_created != 'true' checks, so if even one package releases, the entire PR-creation step is skipped. In this monorepo, the first pass has skip-github-pull-request: true, meaning it never creates or updates release PRs at all. When a subset of packages release (e.g. only server-ai), the remaining packages (langchain, openai, optimization) that have pending changes will not get their release PRs created or updated in that run — they must wait until the next push to main where no package releases, potentially stalling their release cycle.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 26d0727. Configure here.

@devin-ai-integration
Copy link
Copy Markdown
Contributor

Closing: The split release-please pattern is only needed for repos with artifact uploads. This attestation-only repo doesn't need it. The attestation changes are in PR #118.

@kinyoklion kinyoklion closed this Apr 6, 2026
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