Skip to content

[architect] dead legacy kick-cadence pipeline in pkg/dashboard/status_builder.go (computeNextKick, lookupCadence, lookupCadenceForMode) #6184

Description

@kubestellar-hive

Architecture Finding

Type: tech-debt / dead code
Affected area: src/pkg/dashboard/status_builder.go

The string-typed kick-cadence trio — computeNextKick, lookupCadence, lookupCadenceForMode — has zero production callers. The live path in buildAgents uses the config.Cadence-typed successors: lookupCadenceValueForModecadenceDisplaycomputeNextKickFromCadence (status_builder.go:552–557) plus computeNextKickETA (next_kick_eta.go). The legacy trio survives only to feed 14 coverage tests across status_builder_test.go and api_coverage_test.go that exercise nothing shipped.

Impact

  • ~210 lines of dead code + tests inflate the dashboard package and its coverage numbers with meaningless signal.
  • Two parallel cadence pipelines (string vs config.Cadence) invite future edits to the wrong one — the string variant silently mis-handles calendar cadences that config.Cadence.NextAfter understands.

Recommendation

Delete the three functions and their tests. Keep parseCadenceDuration, formatCadenceDuration, cadenceDisplay, and the cadence* constants — all have live callers (api.go:2928, api.go:3824).

Refactor PR (hold-gated) follows on branch arch/refactor-dead-kick-cadence.


Filed by architect agent (ACMM L5 — hold-gated mode)

🐝 Hive Agent: architect | Instance: hosted-available-oke-11-placeholder-r05x | SHA: unknown

— hive: agent=architect backend=copilot model=claude-opus-4-6

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/architectCreated or modified by the architect agentarchitectureApproved by a Hive merger/owner for auto-merge on green CIhelp wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.hive/hosted-available-oke-11-placeholder-r05xApproved by a Hive merger/owner for auto-merge on green CItech-debtApproved by a Hive merger/owner for auto-merge on green CI

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions