Namespaced forge labels never match labelKinds, so kind routing never fires #1590

Closed
opened 2026-10-27 13:41:00 +00:00 by sam · 0 comments
Owner

Every issue in this repo carries namespaced labels (type::feature,
priority::medium, status::in_progress). The label vocabulary at
internal/domain/workintake/subjects.go:48 is keyed on bare strings:

var labelKinds = map[string]Kind{
    "bug": KindBug, "feature": KindFeature, "bootstrap": KindBootstrap,
}

Nothing strips a type:: namespace anywhere in the tree (grep for 'type::'
across .go/.toml/*.yaml returns nothing). So KindsForLabels returns empty
for every real issue, workflowForLabels misses, and Route falls through to
the triage branch at internal/domain/workflow/workflow.go:268.

The comment above that branch states the assumption that is being violated:
"a labelled task already has a free, reliable signal and never reaches here.
Everything else -- overwhelmingly chat-spawned tasks, which rarely carry
labels". Every issue here is labelled and every one reaches there anyway.

Consequence: defaultKindWorkflows (KindFeature -> feasibility, KindBug ->
tdd) has never fired in this repo. Observed on issue 813, a type::feature
that should have routed to feasibility and instead reached implement via
triage, producing PR #859: a producer wired to a NATS subject no stream
carries, with no consumer.

Fix: teach the label layer the namespace::value convention, either in
labelKinds or by stripping a known prefix in KindsForLabels. Red-green:
assert KindsForLabels(["type::feature"]) yields KindFeature.

Close reason

Fixed in PR #870. labelValue() in internal/domain/workintake/subjects.go resolves a label to the value after the last '::' before the labelKinds lookup, so type::feature matches KindFeature. Namespace is deliberately unchecked: bug/feature/bootstrap is a closed three-value vocabulary. Red-green: TestRouteMatchesNamespacedLabels fails Route("type::feature") = "triage", want "feasibility" without the fix.


Imported from beads archie-core-tjoc · GitHub #917 · type bug · priority P1 · created 2026-09-18 · closed 2026-09-18

Every issue in this repo carries namespaced labels (`type::feature`, `priority::medium`, `status::in_progress`). The label vocabulary at internal/domain/workintake/subjects.go:48 is keyed on bare strings: var labelKinds = map[string]Kind{ "bug": KindBug, "feature": KindFeature, "bootstrap": KindBootstrap, } Nothing strips a `type::` namespace anywhere in the tree (grep for 'type::' across *.go/*.toml/*.yaml returns nothing). So KindsForLabels returns empty for every real issue, workflowForLabels misses, and Route falls through to the triage branch at internal/domain/workflow/workflow.go:268. The comment above that branch states the assumption that is being violated: "a labelled task already has a free, reliable signal and never reaches here. Everything else -- overwhelmingly chat-spawned tasks, which rarely carry labels". Every issue here is labelled and every one reaches there anyway. Consequence: defaultKindWorkflows (KindFeature -> feasibility, KindBug -> tdd) has never fired in this repo. Observed on issue 813, a `type::feature` that should have routed to feasibility and instead reached implement via triage, producing PR #859: a producer wired to a NATS subject no stream carries, with no consumer. Fix: teach the label layer the `namespace::value` convention, either in labelKinds or by stripping a known prefix in KindsForLabels. Red-green: assert KindsForLabels(["type::feature"]) yields KindFeature. ### Close reason Fixed in PR #870. labelValue() in internal/domain/workintake/subjects.go resolves a label to the value after the last '::' before the labelKinds lookup, so type::feature matches KindFeature. Namespace is deliberately unchecked: bug/feature/bootstrap is a closed three-value vocabulary. Red-green: TestRouteMatchesNamespacedLabels fails Route("type::feature") = "triage", want "feasibility" without the fix. --- _Imported from beads `archie-core-tjoc` · GitHub #917 · type bug · priority P1 · created 2026-09-18 · closed 2026-09-18_
sam added the highbug labels 2026-10-27 13:41:00 +00:00
sam self-assigned this 2026-10-27 13:41:00 +00:00
sam closed this issue 2026-10-27 13:41:00 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sam/archie#1590