Skip to content

chore: scope v4 branch workflows to v4#40

Merged
aaron-zeisler merged 2 commits into
v4from
aaronz/SDK-2119/release-please-v4-trigger
May 27, 2026
Merged

chore: scope v4 branch workflows to v4#40
aaron-zeisler merged 2 commits into
v4from
aaronz/SDK-2119/release-please-v4-trigger

Conversation

@aaron-zeisler
Copy link
Copy Markdown

@aaron-zeisler aaron-zeisler commented May 26, 2026

Summary

Configure the new v4 branch's GitHub Actions workflows for the v4 release line. This PR targets v4 and introduces no changes to v3v3 stays frozen at its current HEAD.

Three files change:

  1. release-please.yml — trigger on push to v4, with target-branch hardcoded to v4. (See "Why hardcoded v4" below.)
  2. ci.ymlpush and pull_request triggers scoped to [v4, feat/**]. v3 PRs/pushes read v3's ci.yml, so listing v3 here on v4 would be dead config.
  3. check-go-versions.yml — matrix kept at ["v3", "v4"]. This is an intentional cross-reference: after the eventual default-branch flip to v4, this scheduled workflow runs from v4, and the matrix tells it to keep opening Go-version-bump PRs against both branches during v3's deprecation window.

This is one of three parallel PRs across go-jsonstream, go-sdk-common, and go-server-sdk-evaluation. Same change pattern in each.

Why this PR exists

Bundled per Matthew's feedback on the original release-please.yml-only revision: keeps all "set up v4 GHA" work in one PR rather than splitting across multiple. Most importantly, without the ci.yml change the v4 transition PRs in the next stage would have no Go-test signal at PR time — only the external bot checks (Bugbot, UPRA, Semgrep) would gate them.

Why hardcoded v4 and not omitted, and not ${{ github.ref_name }}

An earlier revision of this PR dropped target-branch entirely, on the understanding that the action would auto-detect from the triggering ref. It does not — it falls back to the repo's default branch (release-please-action#913, open since Dec 2023). For us today the default is v3, so omitting target-branch would silently route v4 release PRs to v3.

A later revision used target-branch: ${{ github.ref_name }}. That works for push events — restricted here to v4 by on.push.branches — but workflow_dispatch ignores on.push.branches. A manual run from any branch carrying this workflow file (e.g., a feature branch forked from v4) would resolve github.ref_name to that branch and try to open a release PR against it. Hardcoded v4 closes that gap and matches v3's existing pattern (v3's copy hardcodes target-branch: v3).

Context

Part of the EasyJSON removal effort on SDK-2113, shipping as v4 of these three libraries per semver. Tracked under SDK-2119. Once this lands, the next step is to rebase the existing EasyJSON-removal PR (#39) onto v4.

Test plan

  • YAML lints clean
  • Confirmed: Go-test CI workflows are gated by ci.yml's branch filter; this PR is YAML-only with no Go-code surface to validate. External checks (Bugbot, UPRA, Do Not Merge, Semgrep) still run.

via LD Research 🤖

push:
branches:
- v3
- v4
Copy link
Copy Markdown
Member

@keelerm84 keelerm84 May 26, 2026

Choose a reason for hiding this comment

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

The target branch for the release please action is v3. I believe the latest version of this GHA allows you to omit that branch entirely, and it will infer it from the branch that triggered the run.

Refer to target branch on their docs.

@aaron-zeisler aaron-zeisler force-pushed the aaronz/SDK-2119/release-please-v4-trigger branch from b714978 to 62adaaf Compare May 26, 2026 19:15
aaron-zeisler added a commit to launchdarkly/go-sdk-common that referenced this pull request May 26, 2026
…hardcoded target-branch

Adds the upcoming v4 branch to the release-please workflow trigger so
release-please will activate on v4 once we push it. Also drops the
hardcoded target-branch input — the action infers it from the
triggering branch by default, which means a single workflow file now
works for both v3 and v4 without further per-branch edits.

Aligns with Matthew's review feedback on launchdarkly/go-jsonstream#40.

Part of the SDK-2119 EasyJSON removal project, which is shipping as a
v4 major version per semver.

Co-authored-by: Cursor <cursoragent@cursor.com>
aaron-zeisler added a commit to launchdarkly/go-server-sdk-evaluation that referenced this pull request May 26, 2026
…hardcoded target-branch

Adds the upcoming v4 branch to the release-please workflow trigger so
release-please will activate on v4 once we push it. Also drops the
hardcoded target-branch input — the action infers it from the
triggering branch by default, which means a single workflow file now
works for both v3 and v4 without further per-branch edits.

Aligns with Matthew's review feedback on launchdarkly/go-jsonstream#40.

Part of the SDK-2119 EasyJSON removal project, which is shipping as a
v4 major version per semver.

Co-authored-by: Cursor <cursoragent@cursor.com>
@aaron-zeisler aaron-zeisler changed the title chore: add v4 to release-please workflow trigger chore: add v4 to release-please trigger and drop hardcoded target-branch May 26, 2026
@aaron-zeisler aaron-zeisler force-pushed the aaronz/SDK-2119/release-please-v4-trigger branch from 62adaaf to 811f432 Compare May 26, 2026 19:30
@aaron-zeisler aaron-zeisler changed the title chore: add v4 to release-please trigger and drop hardcoded target-branch chore: add v4 to release-please trigger and use dynamic target-branch May 26, 2026
@aaron-zeisler aaron-zeisler force-pushed the aaronz/SDK-2119/release-please-v4-trigger branch from 811f432 to ad632f0 Compare May 26, 2026 19:59
@aaron-zeisler aaron-zeisler changed the title chore: add v4 to release-please trigger and use dynamic target-branch chore: teach v4 branch to all release & CI workflows May 26, 2026
Comment thread .github/workflows/release-please.yml Outdated
@aaron-zeisler aaron-zeisler changed the base branch from v3 to v4 May 26, 2026 20:10
…versions)

Configures the v4 branch's GitHub Actions workflows for the v4
release line, dropping v3 references where they would be dead config
on this branch. Specifically, on v4:

- release-please.yml: trigger on push to v4 only. target-branch stays
  as ${{ github.ref_name }} for robustness if more branches are added
  later. (Auto-detection is broken — see
  googleapis/release-please-action#913 — so
  the explicit dynamic value is still the safe choice.)
- ci.yml: push and pull_request triggers scoped to [v4, feat/**].
  v3 PRs/pushes read v3's ci.yml, so listing v3 here on v4 would
  be dead config.
- check-go-versions.yml: matrix kept at ["v3", "v4"]. This is an
  intentional cross-reference: after the eventual default-branch
  flip to v4, this workflow runs from v4 and the matrix tells it to
  keep opening Go-version-bump PRs against both branches during v3
  's deprecation window.

Bundled per Matthew's feedback: keeps all "set up v4 GHA" work in
one PR. v3 stays frozen at its current HEAD; this PR introduces no
changes to v3.

Part of the SDK-2119 EasyJSON removal project, which is shipping as
a v4 major version per semver.

Co-authored-by: Cursor <cursoragent@cursor.com>
@aaron-zeisler aaron-zeisler force-pushed the aaronz/SDK-2119/release-please-v4-trigger branch from ad632f0 to 057ac3a Compare May 26, 2026 20:14
@aaron-zeisler aaron-zeisler changed the title chore: teach v4 branch to all release & CI workflows chore: scope v4 branch workflows to v4 (cross-maintain Go versions) May 26, 2026
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 using default effort and found 2 potential issues.

There are 3 total unresolved issues (including 1 from previous review).

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 057ac3a. Configure here.

Comment thread .github/workflows/ci.yml
on:
push:
branches: [ 'v3', 'feat/**' ]
branches: [ 'v4', 'feat/**' ]
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

CI branch filter replaces v3 instead of adding v4

High Severity

The push and pull_request branch filters in ci.yml replace v3 with v4 instead of adding v4 alongside v3. This removes all CI coverage (tests, lint, contract tests) for v3 pushes and PRs. The PR description explicitly states the intent is to "add v4 to the branch lists," and check-go-versions.yml correctly uses ["v3", "v4"], confirming this is unintentional.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 057ac3a. Configure here.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

This is a per-branch workflow file. It lives on the v4 branch, and on push events GitHub Actions reads the workflow file from the branch being pushed to.

The check-go-versions.yml matrix ["v3", "v4"] is deliberately different: it's a schedule workflow, and schedule events read the workflow file from the default branch only.

push:
branches:
- v3
- v4
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Release-please drops v3 branch from push trigger

High Severity

The push trigger in release-please.yml replaces v3 with v4 instead of including both. This prevents release-please from running on v3 pushes, so future v3 releases won't get automated release PRs. The PR description says "add v4 to the push trigger," and the dynamic target-branch: ${{ github.ref_name }} was designed to handle both branches — but only if both are listed.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 057ac3a. Configure here.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Same as above: This is a per-branch workflow file.

@aaron-zeisler aaron-zeisler changed the title chore: scope v4 branch workflows to v4 (cross-maintain Go versions) chore: scope v4 branch workflows to v4 May 26, 2026
This workflow file lives only on the v4 branch (its push trigger is
restricted to v4), so the dynamic `target-branch: ${{ github.ref_name }}`
adds no flexibility — but it does open a workflow_dispatch footgun: a
manual dispatch from any branch carrying this file (e.g., a feature
branch forked from v4) would pass that branch's name to release-please,
potentially creating a release PR against an unintended branch.

Hardcoding `target-branch: v4` locks every push and every manual
dispatch of this v4-branch workflow to the v4 release line, matching
v3's existing hardcoded pattern.

The v3 branch's release-please.yml is unchanged and continues to use
`target-branch: v3`.

Co-authored-by: Cursor <cursoragent@cursor.com>
aaron-zeisler added a commit that referenced this pull request May 26, 2026
Transitions go-jsonstream to its v4 major version per Go's semantic
import versioning. With easyjson removed in the prior commit, this is
the natural moment to take the major bump.

Changes in this commit:
- go.mod: module path /v3 -> /v4
- All .go files: import paths /v3/internal/commontest -> /v4/internal/commontest
- README.md: badge and pkg.go.dev link refs from /v3 -> /v4
- .release-please-manifest.json: 3.1.1 -> 4.0.0
- release-please-config.json: drop bump-minor-pre-major (v4 is post-1.0)

Workflow file (release-please.yml, ci.yml, check-go-versions.yml)
changes for v4 are landing in #40 separately.

Part of the SDK-2113 EasyJSON removal project, shipping these libraries
as v4 majors per the v3 -> v4 strategy.

Co-authored-by: Cursor <cursoragent@cursor.com>
@aaron-zeisler aaron-zeisler merged commit e8b9c10 into v4 May 27, 2026
22 of 23 checks passed
@aaron-zeisler aaron-zeisler deleted the aaronz/SDK-2119/release-please-v4-trigger branch May 27, 2026 16:50
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