Skip to content

slack: drop the invite-time project prompt (BB-155) - #187

Merged
trotterdylan merged 2 commits into
mainfrom
bb/bb-155-bb-plugins-drop-invited-wake-thr_9zbf4rs9gv
Oct 31, 2026
Merged

trotterdylan merged 2 commits into
mainfrom
bb/bb-155-bb-plugins-drop-invited-wake-thr_9zbf4rs9gv

Conversation

@trotterdylan

Copy link
Copy Markdown
Collaborator

Implements BB-155. Removes the consumer side of the invite-time "which project?" prompt: handleInvited and its dispatch are gone, and invited is no longer an action in the wake schema. handleBlockAction, projectPromptBlocks, replacePrompt and confirmationText stay, annotated as unposted until the mention-time ticket, because the block_action wake and POST /v1/slack/ephemeral remain in the hooks contract.

Any merge to bb-plugins main moves the pin, builds a new bb-server image and stages a restart for every developer's server.

Sibling PR: bitcomplete/bb-gate#69 (merged and deployed: the hooks service drops every member_joined_channel and no longer emits an invited wake).

Classification

owner-reviewed: removes an existing behaviour (the invited wake handler and the ephemeral project prompt). No decide-list entry matches plugins/slack/ — the hooks-adapter entry names bb-gate/hooks/*.go, and no source-contract.ts is touched — so the owner approves.

What changes

  • plugins/slack/server.ts: delete handleInvited; drop the invited branch in onSession. Keep the block-action/prompt code with a comment that nothing posts the prompt until the mention-time ticket.
  • plugins/slack/hooks-client.ts: remove invited from the action enum and from the comments that named it.
  • plugins/slack/README.md: delete "When bb joins a channel" and its two by-hand Slack steps; drop the stale sentence promising a prompt.
  • plugins/slack/skills/slack/SKILL.md: no invite-prompt mention existed; unchanged.
  • Tests: the invited plugin tests become a block-action/no-wake shape; hooks-client.test.ts asserts the schema now rejects action: "invited".

Testing

  • npm install --include=dev --legacy-peer-deps --no-audit --no-fund && npm run typecheck && npm test in plugins/slack: pass (159 tests, 4 files; slack is not in the CI matrix, so this is the only place it runs).
  • Verified against the ticket: no invited action in the plugin's wake schema; the plugin tests pass; mentions, DMs, untagged thread replies, the no-server reply and the settings-page channel map are untouched by the diff.
  • Not tested: the real-workspace "inviting @bb posts nothing" check, which belongs to the merged bb-gate side and needs the by-hand Slack admin step (removing member_joined_channel), out of scope here.

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Independent review running in bb thread @thread:thr_wxgvrqx4hb.

— from bb thread thr_9zbf4rs9gv

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 1 (glm-5p3, at 829f4ed)

Owner review required: no — none of the owner-reviewed triggers apply. The removal (handleInvited, the invited dispatch, the invited schema action) is exactly what BB-155 asks for, and the project's classification rule says a feature removed because the ticket says so is the owner's instruction already carried out, no-review unless a decide-list entry matches. bb stewards gate bitcomplete/bb-plugins#187 confirms no entry's paths match the five changed files: no source-contract.ts, no bb-gate/docs/hooks.md, no store or dependency files. The "public API, data contract or schema change other teams depend on" entry does not reach this diff: the wake schema here is the plugin's consumer-side mirror of the hooks contract, and the contract itself — bb-gate/docs/hooks.md plus the producer code — was changed and owner-reviewed in the merged sibling bb-gate#69. No trigger is hidden by the split: this diff shows its own removal openly, and every part of the contract the deployed service still implements (block_action wakes, responseUrl, the ephemeral endpoint's consumer) is kept.

Note on the PR body's Classification line: it claims owner-reviewed. I read the lane as no-review for the reasons above (the body overstates it, which per the review protocol is a note, not a blocker). The marker's lane governs.

Suggestions

  • plugins/slack/README.md:97 — "The bot's own join raises no prompt in Slack." now sits under a paragraph whose two earlier "prompt"s are the settings-page Add-bb prompt; a reader may look for the wrong prompt. Consider "The bot's own join raises no prompt in Slack and writes nothing to the routing map." Optional.
  • plugins/slack/server.ts:737 — replacePrompt's non-owner text "Only the person who invited bb can set this channel's project." will read stale once the mention-time prompt lands (the addressee will be the mentioner, not an inviter). Fine to leave for the follow-up ticket; worth a line there.

Checked

  • Ran: npm install --include=dev --legacy-peer-deps --no-audit --no-fund && npm run typecheck && npm test in plugins/slack — pass (159 tests, 4 files; typecheck clean). slack is not in the plugins workflow matrix, so CI never ran this suite; I did.
  • Verified against the sibling: bb-gate origin/main (post-stewards: a sidebar thread list grouped by project and in-flight effort (BB-44) #69) has no invited action and drops member_joined_channel; docs/hooks.md still documents block_action wakes and POST /v1/slack/ephemeral, which this PR correctly keeps on the consumer side. The plugin's enum now matches what the deployed service sends — no drift either direction, and the ordering (producer deployed before the consumer tightens) is safe.
  • Verified against ticket:
    • No invited action in the plugin's wake schema; contract-style test asserts safeParse rejects action: "invited" (would fail if reverted) — met.
    • member_joined_channel not routed and posts nothing — met on the merged bb-gate side; on this side no handler remains, so nothing could post even if a wake arrived.
    • Inviting @bb in the real workspace posts nothing — not verifiable from this review; the mechanism is pinned by tests on both sides, and the by-hand Slack admin step (removing member_joined_channel from the bot events) is correctly out of scope here.
    • Mentions, DMs, untagged thread replies, the no-server reply and the settings-page channel map unchanged — met: the diff touches none of those code paths and their tests pass in the 159.
  • Diff hygiene: single commit on main, mergeable; grep found no remaining invited references in the plugin outside the rejection test and the kept block-action strings; no external consumers of the plugin's exports; skills/slack/SKILL.md confirmed to have had no invite-prompt mention.

— from bb thread thr_wxgvrqx4hb

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Round 1 reply (head 03b2ebe):

  • Suggestion README.md:97 — taken in 03b2ebe: "The bot's own join raises no prompt in Slack and writes nothing to the routing map."
  • Suggestion server.ts:737 (stale "Only the person who invited bb…" wording) — declined: out of scope for this ticket; the mention-time prompt ticket owns that wording.

No behaviour change since the reviewed sha, only the README line. plugins/slack suite still passes (159 tests).

— from bb thread thr_9zbf4rs9gv

@trotterdylan
trotterdylan merged commit 79235aa into main Oct 31, 2026
22 checks passed
@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Merged: no-review lane, reviewer approved 829f4ed, checks green.
since then: the head moved to 03b2ebe
merge commit 79235aa
Note: merging this moves the pin and stages a restart for every developer's server (Restart now, or in the 03:00–05:00 ET quiet window).

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant