refactor(tms): remove dead port interfaces and their unused mocks - #566
refactor(tms): remove dead port interfaces and their unused mocks#566emoss08 wants to merge 1 commit into
Conversation
Seven port interfaces had no production consumer: nothing implemented them via fx.As or compile-time assertion, and nothing injected them. JurisdictionRuleCacheRepository had zero references anywhere; the other six (TenantSyncService, VersionService, BankReceiptWorkItemService, DataRetentionCacheRepository, JournalReversalService, ManualJournalService) were referenced only by their own generated mocks, none of which any test used. Handlers and resolvers for these features inject the concrete service types directly, so behavior is unchanged; all request/response structs stay because the concrete services and handlers consume them. Kept deliberately: EDIDocumentRepository (a test-fixture aggregate whose mock backs the ediservice and edihandler suites), TenantSyncDelta and the controlplane TenantSyncer chain (the unwired tenant-sync feature is a separate build-or-remove decision), and the .mockery.yaml config (all: true needs no per-interface edits). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015houJkqb8SuqPW4YpLoWCq
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ❌ Deployment failed View logs |
trenova-dash | f6fcc7d | Aug 31 2026, 08:38 PM |
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ❌ Deployment failed View logs |
trenova | f6fcc7d | Aug 31 2026, 08:38 PM |
|
Warning Review limit reachedNext included review available in 59 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (13)
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 |
|
Standing down on the Workers Builds failures (trenova, trenova-dash): this PR only deletes Go interfaces and mocks in Generated by Claude Code |
Description
Removes seven port interfaces with no production consumer, verified by a full-repo reachability sweep of all 308 interfaces in
core/ports/servicesandcore/ports/repositories:JurisdictionRuleCacheRepository— zero references anywhere, not even a mock.TenantSyncService,VersionService,BankReceiptWorkItemService,DataRetentionCacheRepository,JournalReversalService,ManualJournalService— each referenced only by its own generated mock, and none of those mocks are used by any test. The handlers/resolvers for these features inject the concrete service types directly (the resolver fields that share these names hold*journalreversalservice.Serviceetc., not the ports), so behavior is unchanged.All request/response structs stay — the concrete services and handlers consume them.
Kept deliberately:
EDIDocumentRepository— dead in production but a load-bearing test aggregate: its mock backs theediserviceandedihandlersuites (one mock assigned into all eight repo fields).TenantSyncDeltaand the controlplaneTenantSyncerchain — the unwired tenant-sync feature is activated separately in feat(tms): wire the control-plane tenant syncer into the app lifecycle #568..mockery.yaml—all: trueneeds no per-interface edits; deleted interfaces simply won't regenerate.Related Issue or Discussion
Follow-up from the codebase audit driving PRs #557–#564 (dead TMS ports slice).
Type of Change
Scope
internal/core/ports/services/andinternal/core/ports/repositories/internal/testutil/mocks/Validation
cd services/tms && go build ./... && go vet ./internal/core/ports/... ./internal/testutil/...— cleango test ./internal/core/services/... ./internal/api/...— all passgofmt -lclean on touched packagescd client && pnpm build/pnpm lint— not run; no client changesDeployment Notes
Pure dead-code removal; no runtime behavior, API surface, or configuration changes.
Checklist
AGENTS.md,CLAUDE.md, and existing repository patterns.🤖 Generated with Claude Code
https://claude.ai/code/session_015houJkqb8SuqPW4YpLoWCq
Generated by Claude Code