chore: scope v4 branch workflows to v4#40
Conversation
| push: | ||
| branches: | ||
| - v3 | ||
| - v4 |
There was a problem hiding this comment.
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.
b714978 to
62adaaf
Compare
…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>
…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>
62adaaf to
811f432
Compare
811f432 to
ad632f0
Compare
…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>
ad632f0 to
057ac3a
Compare
There was a problem hiding this comment.
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).
❌ 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.
| on: | ||
| push: | ||
| branches: [ 'v3', 'feat/**' ] | ||
| branches: [ 'v4', 'feat/**' ] |
There was a problem hiding this comment.
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)
Reviewed by Cursor Bugbot for commit 057ac3a. Configure here.
There was a problem hiding this comment.
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 |
There was a problem hiding this comment.
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.
Reviewed by Cursor Bugbot for commit 057ac3a. Configure here.
There was a problem hiding this comment.
Same as above: This is a per-branch workflow file.
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>
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>


Summary
Configure the new
v4branch's GitHub Actions workflows for the v4 release line. This PR targetsv4and introduces no changes tov3—v3stays frozen at its current HEAD.Three files change:
release-please.yml— trigger on push tov4, withtarget-branchhardcoded tov4. (See "Why hardcodedv4" below.)ci.yml—pushandpull_requesttriggers scoped to[v4, feat/**].v3PRs/pushes read v3'sci.yml, so listingv3here 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 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, andgo-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 theci.ymlchange 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
v4and not omitted, and not${{ github.ref_name }}An earlier revision of this PR dropped
target-branchentirely, 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 isv3, so omittingtarget-branchwould silently route v4 release PRs to v3.A later revision used
target-branch: ${{ github.ref_name }}. That works forpushevents — restricted here tov4byon.push.branches— butworkflow_dispatchignoreson.push.branches. A manual run from any branch carrying this workflow file (e.g., a feature branch forked fromv4) would resolvegithub.ref_nameto that branch and try to open a release PR against it. Hardcodedv4closes that gap and matches v3's existing pattern (v3's copy hardcodestarget-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
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 🤖