chore(deps): backport go-libs migrator index name fix to release/v3.0#706
chore(deps): backport go-libs migrator index name fix to release/v3.0#706Dav-14 wants to merge 3 commits into
Conversation
Pulls in formancehq/go-libs#596 (backport to release/v3.6, tagged as v3.6.2) which fixes a hardcoded `idx_version_id` name collision between migrators sharing a schema. The bug crashes services with `SQLSTATE 42P10` at startup. Affected DBs self-heal on next deploy - no manual SQL required. Note: this branch sat on go-libs v3.0.0-alpha.2 + Go 1.23. The smallest patched go-libs (v3.6.2) requires Go 1.24, so `go mod tidy` cascades into substantial transitive dep bumps. Build succeeds clean. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Bumps payments v3.0/v3.1 stack pins to v3.0.20 (formancehq/payments#706, draft) and orchestration v3.1/v3.2 stack pins to v2.4.2 / v2.6.1 (formancehq/flows#173 / #172). v3.0 stack orchestration v2.1.1 stays untouched: no release/v2.1 branch exists on flows, so no backport target. Needs separate decision (bump to v2.4.x line or accept the bug there). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. 🗂️ Base branches to auto review (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
The go-libs bump pulled the activities.MockClient onto the v1.35.0 client.Client surface, which adds DescribeWorkflow alongside the existing DescribeWorkflowExecution. The committed mock was last generated against v1.33.0, so the test typecheck failed. Constraint: temporal SDK is pinned at v1.35.0 in go.mod Confidence: high Scope-risk: narrow Directive: client_generated.go has no //go:generate directive — regenerate manually with mockgen against the pinned go.temporal.io/sdk version whenever the temporal SDK is bumped Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
pflag treats Bool flags with NoOptDefVal="true", so `--profiler-enable false` parses as `--profiler-enable=true` plus a positional `false`, leaving the profiler ENABLED in tests. The profiler module then registers a second httpserver hook on port :9090 (or :9191 for the worker), which closes the same `serverport` started channel that the API hook already closed — panic: close of closed channel. The same bug was fixed on release/v3.1+ by switching to the `--profiler-enable=false` syntax, but never backported to v3.0. Surfaced now because go-libs v3.6.2's serverport.StartedServer panics on the duplicate close (the alpha.2 path was either silent or hit a different code path). Constraint: pflag Bool flags require `--flag=value` syntax to consume the value Confidence: high Scope-risk: narrow Directive: when adding boolean test flags, always use `--name=value` (no space) — otherwise the value is parsed as a positional and the flag defaults to true Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## release/v3.0 #706 +/- ##
===============================================
Coverage ? 65.41%
===============================================
Files ? 602
Lines ? 26039
Branches ? 0
===============================================
Hits ? 17034
Misses ? 7942
Partials ? 1063 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
This looks OK, but pending the test on a stack |
Summary
Jira: EN-1029
Backport of the go-libs migrator index name fix to payments
release/v3.0. Bumpsgithub.com/formancehq/go-libs/v3fromv3.0.0-alpha.2tov3.6.2.Pulls in formancehq/go-libs#596 (backport of #594 to
release/v3.6) which fixes a hardcodedidx_version_idname collision between migrators sharing a schema. The bug crashes services withSQLSTATE 42P10at startup. Affected DBs self-heal on next deploy — no manual SQL required.This branch was on go-libs
v3.0.0-alpha.2and Go 1.23.5. The smallest patched go-libs isv3.6.2, which requires Go 1.24.4 — sogo mod tidycascades into ~280 lines of transitive dep changes (watermill, pgx, pgxlisten, otel, temporal, bun, sync/oauth2/text, …).The build is clean (
go build ./...succeeds). But for a release-branch hotfix, this is much heavier than the v3.1 / v3.2 / v3.3 backports.Alternatives to consider before merging:
payments v3.0.xfrom regions and shift v3.0 / v3.1 stacks topayments v3.1.x(where chore(deps): backport go-libs migrator index name fix to release/v3.1 #703 already covers the fix with a much smaller diff).Companion to #701 (main), #703 (release/v3.1), #704 (release/v3.2), #705 (release/v3.3).
Test plan
go mod tidycleango build ./...succeeds🤖 Generated with Claude Code