Repository navigation
chore: remove test harness, docker and reflect2 from prod binaries - #1829
Conversation
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Update re-exec imports common/cmd/cmd.go, common/utils/simulation.go, common/go.mod |
The command and simulation packages import reexec from github.com/moby/sys/reexec. The module adds that dependency directly. |
Remove IsNil and update its caller common/utils/utils.go, common/go.mod, coordinator/cmd/mock_app.go |
The utils package removes IsNil and its reflect2 import. The module lists reflect2 as indirect. CoordinatorApp.Free checks whether Cmd is nil before calling WaitExit. |
Update integration imports and version tag tests/integration-test/integration_test.go, common/version/version.go |
The integration test aliases the coordinator command package as capp and separately blank-imports the API app package. The version tag changes from v4.8.8 to v4.8.9. |
Priority:
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Other
Suggested reviewers: mask-pp, colinlyguo, 0xmountaintop
Merge Risk: 
Minimal · up to 1e16e
-
The changes preserve integration registration while keeping test-only dependencies out of the production API path.
Pre-merge checks: 
5
-
Full details: Title check
-
Explanation
The title uses the conventional commit type "chore" and names the main change: removing the test harness, docker, and reflect2 from production binaries. The raw summary and objectives confirm that the changeset moves mock_app.go out of the coordinator API package, swaps the docker reexec import for moby/sys/reexec, and removes the reflect2-based IsNil helper. The title is clear and specific.
Full details: Description check
-
Explanation
The description covers the purpose, the rationale, and the approach. It explains why each change was made and how it was done, and it gives measurable results (module counts, govulncheck findings). It also fills in the deployment tag and breaking change sections. Two items are incomplete: the PR title section marks only the build type, which matches the title's chore prefix only loosely (the conventional-commit type is not checked as chore, and build is checked instead), and the description gives no test names or commands. The template's conventional commit type list does not include chore, so the title and the checked type disagree.
Resolution
Align the checked conventional commit type with the PR title. The title uses "chore", but the description checks "build". Either change the title type to "build" or check the type that matches the title. Optionally, list the test commands or results that verify the change.
Full details: Docstring Coverage
-
Explanation
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 5 files. (1 skipped: 1 unsupported.)
-
Finishing Touches
-
📝 Generate docstrings
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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 @coderabbitai help to get the list of available commands.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #1829 +/- ##
========================================
Coverage 30.71% 30.71%
========================================
Files 263 263
Lines 22827 22825 -2
========================================
Hits 7011 7011
+ Misses 15127 15125 -2
Partials 689 689
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Purpose or design rationale of this PR
Production binaries linked test-only code:
coordinator/cmd/api/app/mock_app.golived in the coordinator API's production package, socoordinator_apilinkedtesting,testcontainers, docker compose, containerd, buildkit, gRPC and OpenTelemetry. It now lives incoordinator/cmd, likerollup/cmd/mock_app.go. The integration test blank-importscoordinator/cmd/api/appto keep thecoordinator-api-testregistration.common/utilsandcommon/cmdusedgithub.com/docker/docker/pkg/reexec, which pulleddocker/dockerinto every binary. Replaced withgithub.com/moby/sys/reexec(same API).utils.IsNil(usingmodern-go/reflect2) had one caller, on a pointer; replaced with!= nil.Result:
coordinator_api228 → 96 modules. No production binary linkstesting,testcontainers,docker/dockerorreflect2. Reachable govulncheck findings 34 → 6, none new.PR title
Your PR title must follow conventional commits (as we are doing squash merge for each PR), so it must start with one of the following types:
Deployment tag versioning
Has
tagincommon/version.gobeen updated or have you addedbump-versionlabel to this PR?Breaking change label
Does this PR have the
breaking-changelabel?Summary by CodeRabbit
Bug Fixes
Chores