Repository navigation
Closed
Labels
agent/scannerCreated or modified by the scanner agentCreated or modified by the scanner agenthelp wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.kind/featureCategorizes issue or PR as related to a new feature.Categorizes issue or PR as related to a new feature.
Description
Part of #15869
Goal
Add the opt-in config surface for richer RFC publishing, the explicitly designated announcer gate, and the private-repository authorization gate. No card/thread rendering yet. This child makes sure later children can't post anything new unless the operator turned it on.
Applicable decision constraints (from @clubanderson's /hive decision on #15869)
- Opt-in upgrade: keep today's one-line behaviour unless cards/threads are explicitly enabled.
- One explicitly designated announcer per destination; do not let every hive race to publish.
- Do not publish private repository titles, bodies, links or discussions into a channel without an explicit authorized destination policy.
- No live Discord configuration or channel changes: source changes only.
Current code (v5)
src/pkg/config/config.goDiscordConfighasRFCChannelID(rfc_channel_id) plus env overrideHIVE_DISCORD_RFC_CHANNEL_ID(DiscordRFCChannelIDEnvVar, applied around line 5876).src/cmd/hive/rfcnotify_wire.gorfcNotifySettings/rfcNotifyState.ensurebuildrfcnotify.Options{StatePath, IncludeRepo, Logger}.rfcNotifyIssuesmapsgithub.IssueSnapshot→rfcnotify.Issue.src/pkg/rfcnotify/sweeper.goOptions/Sweeper.Run.src/pkg/rfcnotify/rfcnotify.goIssue.- Today every hive with
rfc_channel_id+bot_tokenposts, and private-repo RFCs are posted as well.
Changes
DiscordConfignew keys. Each usesomitemptyand its zero value keeps today's behaviour:rfc_format(""/line= today,card): validate. An unknown value is a config error, or a warning that falls back toline, following the convention of neighbouring keys.rfc_threads(bool, default false).rfc_announcer(bool, default false): this hive is the designated announcer forrfc_channel_id.rfc_backlink_comment(bool, default false). Parsed only here; behaviour lands in a later child.rfc_include_private(bool, default false).
rfcnotify.Optionsgets matching fields (Format,Threads,Announcer,IncludePrivate,Backlink), andensureplumbs them through. A config change rebuilds the sweeper options in the same way a channel change rebuilds the poster today.- Announcer gate. A rich mode is
rfc_format: cardorrfc_threads: true. When a rich mode is configured withoutrfc_announcer: true, the hive keeps advancing its detector state but posts nothing, and logs one warning (rfc notify: rich mode requires rfc_announcer; not posting). Line mode with no new keys stays byte-for-byte unchanged. - Private gate. Add
Private booltorfcnotify.Issue. Inrfcnotify_wire.go, resolve repo visibility once per repo withgithub.Client.GetRepoand cache it onrfcNotifyState; refresh it at most hourly. Any failure to resolve counts as private (fail closed). The sweeper drops events for private-repo issues unlessIncludePrivateis set, but the detector record still advances so nothing replays later. This applies in every mode, line mode included, because the decision makes it an authorization requirement.
Decision taken by hive: the gate lives in rich mode only, so existing line-mode users see no change. The private gate covers all modes and fails closed, as the decision requires. It ships with a security changelog fragment.
Files
src/pkg/config/config.go(+ a test insrc/pkg/config/)src/pkg/rfcnotify/sweeper.go,src/pkg/rfcnotify/rfcnotify.gosrc/cmd/hive/rfcnotify_wire.go(+rfcnotify_wire_test.go)src/docs/notifications.md(RFC section: new keys table, announcer and private rules)
Acceptance
- With no new keys set, the posted lines are identical to today (existing
rfcnotify_test.gostays green). rfc_format: cardwithoutrfc_announcer→ zero posts plus one warning. The state still advances, so enabling the announcer later does not backfill.- An RFC in a private repo (or one whose visibility can't be resolved) is not posted unless
rfc_include_private: true. - Tests:
src/pkg/rfcnotify/rfcnotify_test.go(gates),src/cmd/hive/rfcnotify_wire_test.go(plumbing, visibility cache, fail closed), and a config parse/validation test. Coverage floors: rfcnotify uses the defaultTHRESHOLD=90andcmd/hiveis 42 (.github/workflows/v2-tests.ymlPKG_THRESHOLD). changelog.d/security-rfc-notify-private-gate.mdfragment.
— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88
Metadata
Metadata
Assignees
Labels
agent/scannerCreated or modified by the scanner agentCreated or modified by the scanner agenthelp wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.kind/featureCategorizes issue or PR as related to a new feature.Categorizes issue or PR as related to a new feature.
Activity
clubanderson commentedon Oct 31, 2026
@hanthor Tracking implementation of your RFC #15869 here. Implementer requirement: mention @hanthor in the associated PR description, link this issue and RFC #15869, and post a completion comment mentioning @hanthor after the PR actually merges, with the merge link and a clear distinction between source shipped and deployment/activation. This issue is still open; this comment is attribution/notification, not a completion claim.
hivecommons-hive commentedon Oct 31, 2026
🔒 Claimed by agent
scanner(agent on hive hosted-available-oke-11-placeholder-r05x). The claim lasts 2h0m0s without activity and renews while the work continues. Reply/unclaimto release, or/claimto take it over if you outrank the holder.