Skip to content

πŸ› fix(advisory): never reopen an advisory issue a person closed - #16838

Merged
hivecommons-hive[bot] merged 1 commit into
hivecommons:v6from
Danathar:fix/advisory-honour-person-close
Nov 5, 2026
Merged

hivecommons-hive[bot] merged 1 commit into
hivecommons:v6from
Danathar:fix/advisory-honour-person-close

Conversation

@Danathar

@Danathar Danathar commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Executive summary

projectbluefin/common#639 is the June advisory digest. A maintainer closed it on 2026-10-27 at 20:51Z, with the comment "no longer used". The hive reopened it the next day at 17:14Z, re-added hive/advisory, and the issue was parked at 045. No comment was posted. The reopen is #4167's deliberate reuse of a closed advisory issue, which keeps subscribers on one URL. That reuse doesn't distinguish an accidental close from a person's decision.

With this PR, a person's close stands. The hive leaves that issue closed and files a new advisory issue. The new issue says which one it replaces and why, and names advisory.target as the setting that moves the digest off GitHub. A close by the hive or a bot, or one GitHub doesn't attribute, is reused exactly as before.

What

Closed advisory issue, closed by Before After
A person (closed_by is a user, not this hive) Reopened Left closed; new advisory issue opens with "This replaces #N, which X closed on DATE …"
This hive, another bot, or nobody GitHub names Reopened Reopened (unchanged, #4167)

The new issue's opening paragraph covers three things:

  • Hive does not reopen an issue a person closed.
  • advisory.target: linear (with advisory.linear_issue) keeps the digest off GitHub.
  • To go back, reopen the old issue and close the new one.

The closer's login appears without @, so the closer isn't notified.

How

  • advisory_person_close.go (new):
    • advisoryClosedByPerson reads closed_by. It counts as a person unless the login is empty, has the Bot type or a [bot] suffix, or is this hive's account.
    • advisoryReusable fetches the issue when the caller has no copy and records a note for the next create.
  • advisory.go: fallback 3 (closed reuse) reopens only when advisoryReusable agrees. EnsureAdvisoryIssue prefixes the replacement note to the new issue's body.
  • advisory_forgestate.go: the cache path (confirmAdvisoryIssue) applies the same check. On a person's close it forgets the memo and falls through to the list path, which then creates the new issue.
  • docs/advisory.md: the "Someone closed the pinned issue" entry now covers both cases.

Tests

Test Covers
TestEnsureAdvisoryIssue_HonoursPersonClose maintainer close β†’ new issue with the note, no reopen; hive/bot/unknown β†’ reopen
TestFindAdvisoryIssue_CachedPersonCloseNotReopened memoized number on the cache path, no reopen, no cache mutation, note consumed
Existing #4167 reuse tests unchanged and passing
Mutants 5/5 caught
go test github, writeback; docs citations pass; 2006 verified

Notes

πŸ€– Generated with Claude Code

https://claude.ai/code/session_01BQYnPGFJx81c8JXR3o1sg1

projectbluefin/common#639: a maintainer closed the advisory digest ("no
longer used") on 2026-10-27; the hive's hivecommons#4167 reuse reopened it the next
day with no comment. A person's close now stands, on both the list and
the ForgeState-cache path: the hive files a new advisory issue that says
which one it replaces and why, and names `advisory.target`. A close by
the hive or a bot, or one GitHub does not attribute, is reused as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BQYnPGFJx81c8JXR3o1sg1
Signed-off-by: Danathar <Danathar@users.noreply.github.com>
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Nov 5, 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 Nov 5, 2026
@hivecommons-hive
hivecommons-hive Bot merged commit 4e82845 into hivecommons:v6 Nov 5, 2026
71 of 74 checks passed
@hivecommons-hive

Copy link
Copy Markdown
Contributor

Hive status β€” updated in place; edits do not notify. Full history is in the Activity Monitor.

Evidence bundle `#16838c56db03` sha256:446c351d8cac30f546c2069e259d672dd96cb1dad6961bd85fba7f72375c6816 β€” download from the dashboard or `hivectl review evidence #16838`.

@hivecommons-hive

Copy link
Copy Markdown
Contributor

merged by Hive trusted-author auto-merge: author @Danathar holds role owner and GitHub permission maintain on repo; CI green at c56db03.

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

Labels

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.

1 participant