Skip to content

🐛 Every hive-filed issue title starts with its [agent] tag - #15778

Merged
hivecommons-hive[bot] merged 2 commits into
v5from
fix/agent-issue-title-prefix
Oct 30, 2026
Merged

hivecommons-hive[bot] merged 2 commits into
v5from
fix/agent-issue-title-prefix

Conversation

@clubanderson

Copy link
Copy Markdown
Member

Closes #15777

What

Owner rule: "agents that need to open issues need to use [agent name] in the description. I see reviewer is not following this format." #15673 introduced the [<agent>] title tag for some producers; this makes it hold for every hive issue-creation path, with one function and a guard test so no producer can drift again.

  • One choke point. issueshape.AgentIssueTitle(agent, title) replaces TitleFor. Idempotent; normalises a leading tag for the same agent ([Reviewer]x → [reviewer] x); keeps a tag another hive filer already added ([selfreport] … relayed by the governor); treats a non-slug bracket ([ACMM L0], [Tests]) as subject and still tags it; always puts the tag first, ahead of any leading emoji (🐛 [reviewer] x → [reviewer] 🐛 x).
  • Producers wired (each also carries its agent/<lane> / origin/<source> label through the existing label-ensure path with the 🐛 github: keep label descriptions within GitHub's 100-char cap #15685 clamp):
    • CreateIssue — review backlog [reviewer], dedupe [dedupe], self-report [selfreport] (+ origin/selfreport), dashboard/ACMM [dashboard], convergence [convergence] via the forge seam, any agent request through the watcher
    • hotspot filer — now [ci-maintainer], matching its agent/ci-maintainer label (was [governor])
    • advisory living document [governor] 🐝 Hive Advisory Report and recommendations [governor] 🐝 Hive recommendations — … — both were raw Issues.Create calls that bypassed the helper; their lookups now compare with the tag ignored (isAdvisoryTitle / SameTitle) so an upgrade never opens a second standing issue
    • upstream-watch raw filer [governor]
    • egress proxy for an agent's raw gh issue create
  • Guard tests. pkg/issueshape/choke_point_test.go walks src/ and fails any non-test Go file calling Issues.Create( without issueshape.AgentIssueTitle(; a table test asserts each producer's title matches ^\[[a-z0-9-]+\] and re-tagging is a no-op. Helper table tests cover idempotence, duplicate-tag stripping, emoji ordering and the non-filer bracket.
  • Activity Monitor. The leading tag is drawn once as a ham-title-tag chip ahead of the title; the title text no longer repeats it; the full title stays in the tooltip. Non-slug brackets stay in the title. Covered in TestStageTrackerRows.
  • Docs: getting-started, review-swarm, operator-reference (hotspot title). Changelog fragment changelog.d/fixed-agent-issue-title-prefix.md.

Not done on purpose

Tests

go test ./pkg/github/ ./pkg/dashboard/ ./pkg/issueshape/ ./pkg/hotspot/ ./pkg/upstreamwatch/ ./pkg/gfi/ ./pkg/fleetreport/ ./pkg/convergence/... ./pkg/forge/... ./crux/... ./cmd/hive/ + go vet + make dashboard-gen-check. No new time.Sleep.

One function, issueshape.AgentIssueTitle, is now the choke point every
hive issue-creation path runs its title through: CreateIssue (review
backlog, dedupe, selfreport, dashboard, convergence via the forge seam),
the hotspot filer (tagged [ci-maintainer] to match its agent/ci-maintainer
label), the advisory and recommendations living documents and the
upstream-watch filer (raw Issues.Create calls that bypassed the helper),
and the egress proxy for an agent's gh issue create. The tag always comes
first, ahead of any emoji; a title another hive filer already tagged is
kept; a non-slug bracket ([ACMM L0]) is subject, not filer. Advisory and
recommendations lookups compare with the tag ignored so a hive upgrade
never opens a second standing issue.

A guard test fails any non-test Go file that calls Issues.Create without
running its title through AgentIssueTitle, and a table test checks each
producer's title. The Activity Monitor draws the leading tag as a chip
ahead of the title instead of repeating it. Existing issue titles are
left as they are.

Closes #15777

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@clubanderson
clubanderson requested a review from hanthor as a code owner October 30, 2026 14:13
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Oct 30, 2026
@kubestellar-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign clubanderson for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubestellar-prow kubestellar-prow Bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 30, 2026
@github-actions

github-actions Bot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#15748 🐛 [reviewer] park PRs at 085 Needs decision when the fixer exhausted its attempts same files src/docs/review-swarm.md
#15783 🐛 stage tracker: Let hive decide shows it is working, covered issues drop the PR's chip, 👤 says why same files src/pkg/dashboard/static-src/css/tracker.css
src/pkg/dashboard/static-src/js/tracker-row.js
src/pkg/dashboard/static/index.html
#15771 🌱 refactor: split tracker row source CONFLICT src/pkg/dashboard/static-src/js/tracker-row.js
#15757 ✨ Auto-merge hive-authored superseding PRs without operator decision same files src/docs/operator-reference.md
src/docs/review-swarm.md
#15731 📖 docs: split the operator reference same files src/docs/operator-reference.md
#15774 ✨ dashboard: onboarding and GitHub App errors point to the Getting Started guide same files src/docs/getting-started.md
src/docs/operator-reference.md
src/pkg/dashboard/static/index.html

@hivecommons-hive

Copy link
Copy Markdown
Contributor

@clubanderson this PR is held at stage/071-needs-author and the hive will not merge it yet.

Failing checks:

  • test (dashboard 2/4)
  • test (dashboard 3/4)
  • test (dashboard 4/4)
  • test (dashboard shuffle 2/3)
  • test (dashboard shuffle 3/3)

Next: the hive does not push to your branch. Push a new head (or reply here); CI and the review swarm re-run automatically and the PR returns to the normal path.

…ss; ACMM gap title leads with [dashboard]

Signed-off-by: Andrew Anderson <andy@clubanderson.com>

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Read AgentIssueTitle and every caller it replaces; the logic is sound and no TitleFor reference is left behind. One verified gap worth knowing about, not a blocker.

Low — src/crux/issueshape/issueshape.go:112,135-137: a lowercase subject bracket still suppresses the agent tag. IsFilerTag is a shape test (^[a-z0-9][a-z0-9_.-]*$), and the case lead == "" branch returns the title unchanged whenever the leading bracket passes it. So [ci] flaky test on arm64 or [docs] broken link filed by the scanner through the proxy comes out untagged, while [Tests] … and [ACMM L0] … now correctly get [scanner] in front. The old regex had the same hole for every bracket, so this PR narrows it rather than widening it — but the title's claim ("every hive-filed issue title starts with its [agent] tag") is still not strictly true at the crux boundary, where no agent roster is available to distinguish [ci] from [scanner]. If that matters, the proxy side knows lane and could accept only tag == lane or a tag it has seen as a lane; otherwise a one-line note on IsFilerTag saying this is shape-only would stop the next reader assuming it is a roster check.

What I checked holds:

  • AgentPrefix returns "" when an emoji precedes the bracket (🐛 [reviewer] x), so StripAgentPrefix leaves such titles whole; that is fine because AgentIssueTitle normalises to [reviewer] 🐛 x on the way out, and the test at issueshape_test.go:155 pins it.
  • Dedupe keys are unchanged for pre-existing issues: SameTitle("[ACMM L0] …", "[dashboard] [ACMM L0] …") is covered (issueshape_test.go:161), and isAdvisoryTitle (src/pkg/github/advisory.go:33) means the governor-tagged advisory matches an untagged one filed before this change, so no repo gets a second advisory.
  • TestEveryIssueCreatePathTagsTheTitle (src/pkg/issueshape/choke_point_test.go:25) is the right ratchet for the "every path" claim — a raw Issues.Create without the tag fails in CI, not in production.

CI on this head was still running when I read it.

— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive
hivecommons-hive Bot merged commit dbc0749 into v5 Oct 30, 2026
74 of 75 checks passed
@kubestellar-prow
kubestellar-prow Bot deleted the fix/agent-issue-title-prefix branch October 30, 2026 14:43
@hivecommons-hive

Copy link
Copy Markdown
Contributor
Evidence bundle `#1577823ad375` sha256:c51fb8d2ff50354cef4ce85a81c69e4fd6930c88658ce601a072b141d2529c2d — download from the dashboard or `hivectl review evidence #15778`.

@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Your PR has been merged.

We'd love to hear how your experience was: share feedback

hivecommons-hive Bot added a commit that referenced this pull request Oct 30, 2026
…ode into the split files

tracker-row.js conflicted: v5 (#15801 push progress, #15778 title tag chip)
edited code this PR moved out. The pushedBack detour guard stays in
tracker-row.js; the Push tooltip line and push chip go to tracker-row-strip.js;
push: lp.push fields, the pushed lineage suffix and stageTrackerSplitTitleTag /
stageTrackerTitleHtml go to tracker-row-layout.js. index.html regenerated
(unchanged).

Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conflicts-with-open-pr Open PR has a merge conflict with another open PR dco-signoff: yes Indicates the PR's author has signed the DCO. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Every hive-filed issue title must start with its [agent] tag — reviewer, dedupe, hotspot, advisory still miss it

1 participant