Skip to content

fix(slack): name the manifest slash command after the alias - #18550

Merged
iamwhatever merged 1 commit into
mainfrom
fix/11386-slack-command-per-alias
Oct 14, 2026
Merged

iamwhatever merged 1 commit into
mainfrom
fix/11386-slack-command-per-alias

Conversation

@iamwhatever

@iamwhatever iamwhatever commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Each new Kiro Crew Slack app registers its own slash command, so installs in one Enterprise Grid org stop stealing each other's /kirocrew.

The bundled Slack manifest names the app KiroCrew-<alias> but hard-codes command: /kirocrew. Slack resolves slash-command names across a whole Enterprise Grid org. When two people install Kiro Crew there, both apps register /kirocrew, and Slack sends the command to the wrong app (invalid_service).

Why it matters

Anyone in a Grid org with a second Kiro Crew install loses slash commands (/kirocrew dashboard, /kirocrew sessions, ...) with no clear error.

Not a goal

  • Renaming the command of an existing install. A configured slack.command keeps today's command.
  • A dashboard alias input. The dashboard's one-click manifest keeps its generic alias kirocrew, so it keeps /kirocrew.
  • Changing how the gateway matches the command (/{slack.command} only).

What changed (motivation → approach → change)

Slack routes /kirocrew to whichever Grid app claimed it, because every install registers the same name. The fix names the command after the alias, like the app name already is, and every path that hands out an alias-named command also tells the person which slack.command the gateway needs.

Path Command it registers How the person learns the slack.command step
kirocrew manifest (stdout, --url, -o) /kirocrew-<alias> prints the kirocrew config set slack.command ... line (stderr when stdout is the manifest)
GET /api/slack/manifest?alias=<x> /kirocrew-<x> the response names it as command
Settings → Slack (one-click link, no alias) /kirocrew no step: the default slack.command answers it, as on main
kirocrew setup --slack n/a unchanged default (kirocrew or the configured command)

The command in src/kiro_crew/slack-manifest.yaml is a {{COMMAND}} slot filled by slash_command(alias) in src/kiro_crew/slack_manifest.py: lowercase, cut to Slack's 32-character limit. src/kiro_crew/cli_setup.py prints the hint and labels the wizard prompt Slash command name (must match your Slack app, e.g. kirocrew-<alias>); the wizard's default does not move, because it cannot know which alias the app was created with. The exfil deep-link validator in security/exfil.py reads that slot as a group and requires it to equal slash_command(alias), so the exempted link still carries nothing beyond the alias.

The dashboard writes no config, so its one-click link keeps the generic command. Settings → Slack sends no alias, and its app registers /kirocrew, which an unconfigured gateway answers on the first try. An alias-named command there would go unanswered until the person ran a terminal step, so dashboard installs in one Grid org still share /kirocrew; a Grid user who needs a distinct command creates the app with kirocrew manifest. A caller that passes ?alias= to api_slack_manifest in src/kiro_crew/dashboard/handlers/messaging.py gets /kirocrew-<alias>, and the response's command field names the slack.command value it needs.

An older install that re-imports the bundled manifest, as the scope-probe hint and the setup guide's upgrade note advise, gets /kirocrew-<alias> while slack.command stays kirocrew. Both notes (slack/scope_probe.py, docs/guides/slack-setup.md) name that rename and the config line. If it happens anyway, _handle_slash in src/kiro_crew/slack/events.py still runs nothing, and matching is unchanged. A name the manifest can register (/kirocrew or /kirocrew-<alias>) gets a WARNING log and, for the owner only, an ephemeral reply: "⚠ Kiro Crew is set up for /kirocrew, so /kirocrew-<alias> did nothing. To use /kirocrew-<alias>, run kirocrew config set slack.command kirocrew-<alias> and restart the gateway." Any other name is dropped.

The setup guide and the security, slack-gateway and messaging specs describe the default, the command field and the reply.

Default design call, needs maintainer sign-off: apps created with kirocrew manifest get /kirocrew-<alias>, and the user runs the printed config set line; existing installs keep their configured slack.command. This changes a default and no RFC records it, so First Principles asks for a maintainer ruling, which binds one head.

Backwards compatibility

Compatible: no stored slack.command changes, the wizard's default is unchanged, and the dashboard's one-click link registers /kirocrew as before; only a newly created CLI app registers the alias command. GET /api/slack/manifest keeps every field and adds command. The gateway runs the same commands as before; a mismatched manifest-shaped command gets a reply where it got none.

Removes nothing: the manifest gains a slot, the endpoint a field and the gateway a reply; no key, path, or accepted input goes away.

Tests

test/test_slack_manifest_command.py (16 tests):

  • the rendered command is /kirocrew-<alias>, differs per alias, is lowercase and at most 32 characters at ALIAS_MAX; alias kirocrew keeps /kirocrew;
  • the real deep link for a long mixed-case alias is not redacted, and a payload whose command does not match its alias is;
  • the wizard keeps kirocrew for an unconfigured install; kirocrew manifest --url prints the matching config set line, and plain kirocrew manifest prints it on stderr with a clean manifest on stdout;
  • the dashboard endpoint: ?alias=JDoe returns command kirocrew-jdoe, the one command in its manifest; the request Settings → Slack makes (no alias) returns the SlackConfig default slack.command, so that app works on the first try;
  • the scope-probe reinstall notice names /kirocrew-<alias> and the kirocrew config set slack.command line;
  • an old install sent the re-imported manifest's real /kirocrew-jdoe: the owner gets one ephemeral reply naming kirocrew config set slack.command kirocrew-jdoe, a WARNING names the same line, nothing runs or is audited; a non-owner gets no reply; /other and /kirocrew-x;id get no reply.

Red-before on the previous head 3f631c0d9d: both endpoint tests fail (KeyError: 'command') and the reinstall-notice test fails (no /kirocrew-<alias> in the notice). On 569df44d53 the owner-reply test failed (assert 0 == 1); mutations of that reply (no reply, no owner gate, a startswith in place of the shape match, no shape match, WARNING downgraded to DEBUG, the return dropped) each redden it.

Determinism: the three new tests 20 runs each at -n0; the file 10 runs at -n 2 --dist loadgroup beside test/test_slack_scope_probe.py, test/test_slack_config_handlers.py and test/test_slack_manifest_scopes.py; the whole file once with its 16 node ids in a shuffled order (seed 24601): all green. The new tests share no state: each builds its own request, orchestrator stand-in or probe client.

Scoped suites green here: 797 backend tests (the Slack, manifest-endpoint, messaging-handler and CLI-setup suites, TestKiroCrewSlackAppCreateLink); isort, flake8, black and mypy on the changed Python, and the comment-history, brand-name, feature-map and docs-lint gates and the flake-pattern and wait-discipline ratchets.

Manual verification

N/A — unit coverage drives the real emitters (render, deep_link, _manifest, _setup_slash_command), the real api_slack_manifest and the real _handle_slash with only the Slack HTTP post stubbed; creating a Slack app needs a Grid org. No dashboard UI changes.

Related Issues

Closes #11386

Taskei: CREW-19831. Takes over #11398 by @DcXiaoBing (credited as co-author).

Pattern harvest

Not generalizable: a single hard-coded org-global name in a per-install template.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@iamwhatever
iamwhatever requested review from a team and KiroCrewCaptain as code owners October 9, 2026 18:03
@iamwhatever
iamwhatever requested a review from CrysisDeu October 9, 2026 18:03
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Oct 9, 2026
@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Sensitive Change Review

Sensitive files changed:

  • src/kiro_crew/security/exfil.py

  • @iamwhatever posted a complete reasoning template for 867f259.

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision 867f2596b692ca21a26c8604009f1ff5eb4f1b56 touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Advisory — does not block merge.

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ human override accepted

@iamwhatever overrode this lane for 867f2596b692ca21a26c8604009f1ff5eb4f1b56 via /ai-review override (this commit only).

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — 🟡 CONCERNS

Design-level review of 867f2596b692ca21a26c8604009f1ff5eb4f1b56 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: CONCERNS

New CLI installs now register /kirocrew-<alias>, but the gateway still answers only /kirocrew until the user runs a printed config line, so the default setup no longer works without it.

Watch

  • The new default only works after a manual step. The hunk print(hint, file=sys.stderr) and the unchanged wizard default [{current}] (still kirocrew) leave the generated app and slack.command disagreeing. A user who misses the stderr hint, or accepts the wizard's default, ends up with a slash command that does nothing. The only signal is an owner-only ephemeral reply. Before this PR, the CLI path worked as soon as it was set up, in every workspace, not just Grid orgs.
    Clears when: a fresh kirocrew manifest→kirocrew setup --slackrun ends with the two names matching, with no hand-copied line (for example, the manifest step writesslack.command, or the wizard defaults to slash_command(alias)).
  • The Grid routing claim is untested. "Manual verification: N/A" rests on Slack's Grid-wide command routing (invalid_service), and CI cannot check that. If it is wrong, every new CLI user takes on the rename for nothing. A revert would undo it.
    Clears when: an issue link, Slack doc citation or Grid repro shows two apps sharing /kirocrew misroute, and that distinct names fix it.

Suggestions

  • _MANIFEST_COMMAND_RE already detects a manifest-shaped command, and Slack only delivers commands this app registered. The gateway could simply accept that shape and run it, which removes the config step, the mismatch reply and the wizard confusion. That would mean revisiting the "Not a goal" line about gateway matching, so it needs the maintainer's ruling the PR already asks for.

[DESIGN-REVIEWED] 867f259

Description read

[DESCRIPTION-READ] 16db8c572b54ede193c7043246f5be09676cf3e1d213bac8f97a243c52fe66d3

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of 867f2596b692ca21a26c8604009f1ff5eb4f1b56 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] 867f259

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 867f2596b692ca21a26c8604009f1ff5eb4f1b56: <one-sentence reason>

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 867f2596b692ca21a26c8604009f1ff5eb4f1b56 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 867f259

Verdict parsed from the review's SHA-scoped output markers for commit 867f2596b692ca21a26c8604009f1ff5eb4f1b56.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 867f2596b692ca21a26c8604009f1ff5eb4f1b56: <one-sentence reason>

@iamwhatever

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 6d63bdc
  • What rule changed: the Slack app-create deep-link carve-out in _kirocrew_slack_app_link_alias reads the manifest's new {{COMMAND}} slot as a command group and accepts the link only when it equals slack_manifest.slash_command(alias).
  • Before -> after (what was allowed/blocked, now): before, a payload matching the template with one alias was exempt from the base64/length heuristics. After, the same, and the command slot must also equal the value derived from that alias; any other command is redacted as before. Nothing new is exempt.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): our own kirocrew manifest --url link gets redacted again (setup inconvenience). No secret path: the command is a pure function of the alias, and the alias is still scanned by the heuristics.
  • Evidence checked (which sandbox result proves it): N/A - no sandbox rule moved; test/test_security.py::TestKiroCrewSlackAppCreateLink and test/test_slack_manifest_command.py::TestDeepLinkValidator (real emitter unredacted for a 32-char mixed-case alias; mismatched command redacted).
  • No regression:
    • Tools still work (which tools/commands were run, result): kirocrew manifest --url path via cli_setup._manifest in tests prints an unredacted link plus the config set hint.
    • Backward compatible (old config / old data / old callers still work, how checked): yes; the dashboard alias kirocrew still renders /kirocrew, existing slack.command values are untouched (TestSetupWizardDefault).
    • Existing tests (which suites passed on this head): test/test_security.py::TestKiroCrewSlackAppCreateLink, test/test_security_gate_liveness.py (package line budget unchanged at 28,581 <= 28,582), test/test_slack_manifest_scopes.py, test/test_slack_manifest_command.py.
  • How to undo: revert this PR's commit; the template and validator return to the single-alias form.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=34a0f039c688 Item 1, the manifest default /kirocrew-

needs-a-decision: maintainer ruling wanted on new CLI-created apps registering /kirocrew-<alias> instead of /kirocrew (GH #11386, Grid collisions).
Existing installs are unaffected: a configured slack.command or stored tokens keep the command; the dashboard alias kirocrew keeps /kirocrew.
No RFC exists; a maintainer can record the decision with /ai-review override first-principles <head> or ask for an RFC.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=7d47724c2bb2 Item 2, the wizard default on a first Slack setup

needs-a-decision: same ruling as item 1. The wizard offers kirocrew-<alias> only when no slack.command is configured and no Slack token is stored.
Every other path keeps kirocrew, so the default moves only for installs that have not registered a command yet.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=cb4ced900c75 product-shape change without accepted RFC

needs-a-decision: correct that no RFC covers this. The PR body states the default and that it needs maintainer sign-off.
The agent will not self-override; this waits on a maintainer override or an RFC.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=9bc056f9769b Unverified provider premise

needs-a-decision: a real Slack app creation needs a workspace (ideally a Grid org) the agent cannot use.
Unit tests pin the rendered command to ^/[a-z0-9_-]{1,31}$ at ALIAS_MAX and the gateway match is unchanged (/{slack.command}).
A maintainer can run kirocrew manifest --url --alias <long-alias>, create the app, kirocrew config set slack.command <printed>, and try /<printed> status; or override.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=5f909feb8d92 wizard offers kirocrew-$USER after manifest --alias foo

rebutted: the prompt shows the default and says (must match your Slack app); kirocrew manifest --alias foo prints kirocrew config set slack.command kirocrew-foo.
The wizard cannot know which alias the app was created with; storing it would add a new config key for a rare path, out of goal.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=90abbc6b027b dashboard token entry never sets slack.command

rebutted: the dashboard manifest uses alias kirocrew, which renders /kirocrew, the gateway default, so dashboard-only setups match.
Mixing a CLI manifest with dashboard tokens is covered by the config set line the CLI prints; the dashboard Slash command field edits the same key.

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Security Scope Review -- 🟡 CONCERNS

Which legitimate operations does 867f2596b692ca21a26c8604009f1ff5eb4f1b56 newly refuse? Updated in place on each push. A script-confirmed regression blocks; the model proposes candidates and never decides a refusal.

Verdict basis: the reviewer's own judgement; no confirmed regression.

Security scope review -- adjudicated candidates

  • macos-latest (platform posix): 11 classified, 0 newly refused, 11 still allowed.
  • ubuntu-latest (platform posix): 11 classified, 0 newly refused, 11 still allowed.
  • windows-latest (platform windows): 10 classified, 0 newly refused, 10 still allowed.

No candidate flipped from allowed to refused.

Scope-Verdict: CONCERNS

TIGHTENING: The Slack app-create deep-link carve-out in the exfil URL classifier (_slack_manifest_payload_re / _kirocrew_slack_app_link_alias, src/kiro_crew/security/exfil.py) got stricter. It now pins the manifest's slash-command name to the alias. Before, the template's literal /kirocrew was accepted with any alias. Now {{COMMAND}} becomes a captured group, and the hunk adds if match is None or match["command"] != slack_manifest.slash_command(match["alias"]): return None. The one threat it refuses: a manifest_yaml payload whose slash command does not match its alias, i.e. a command slot used as a second free-form, caller-chosen span. pattern = re.escape(parts[0]).replace(*command_slot) makes it a [a-z0-9_-]+ group. Without the pin, that span would escape the base64 and length heuristics. The test test_a_command_that_does_not_match_the_alias_is_redacted names it.

ADJUDICATED: 14 candidates, 0 confirmed newly-refused (the deterministic fold has not reported yet; no verdicts were handed to this review). None of these rows reach the tightened code. The carve-out is not in the shell deny composite: audit_bash_exfiltration does not call _exfil_url_warning, and SHELL_DENY_TIERS (sensitive-bash, exfil, deny-rules) is not changed by this diff. The rows only probe the operations maintainers run around the change: kirocrew manifest, kirocrew config set|get slack.command, kirocrew setup --slack, and local /api/slack/manifest queries.

PLATFORM COVERAGE: Rows were written for any, posix and windows.

  • any: the kirocrew subcommands and the pytest run.
  • posix: a relative -o path, a > redirect, curl with single quotes, grep.
  • windows: a C:\Users\… -o path, curl.exe with double quotes, PowerShell Invoke-RestMethod.

The diff itself assumes nothing about the platform. Its only new assumption is about argv and string shape: a lowercase [a-z0-9_-] command, cut to 32 characters, with a kirocrew- prefix. That is host-independent, so no platform spelling is left unprobed. The open gap is the guard itself, below.

UNADJUDICATED:

  • Guard: the URL exfil verdict's Slack manifest carve-out. It is _kirocrew_slack_app_link_alias, called from _exfil_url_warning (exfil.py:993) and from diagnose_oauth_url_credential (exfil.py:1792).
  • Call path: the agent or tool output text containing the link goes through scan_exfiltration_urls or redact_exfiltration_urls(_with_records), then _exfil_url_warning, then _kirocrew_slack_app_link_alias, then _slack_manifest_payload_re().fullmatch(manifest_yaml) and the new command/alias pin. If the pin fails, the link is shown as [REDACTED: suspicious URL to api.slack.com].
  • Why it cannot be a row: the shell classifier never runs this path. The payload is about 1.9 KB before percent-encoding, which is over the 512-character row cap anyway.
  • Legitimate inputs I would have submitted:
    1. The deep link kirocrew manifest --url prints for alias jdoe (expect /kirocrew-jdoe).
    2. The link for the mixed-case alias First-Last_QQQQ… at ALIAS_MAX (expect a lowercase command cut to 22 alias characters).
    3. The dashboard's default-alias create_url (alias kirocrew, expect /kirocrew).
    4. A link printed by an earlier kirocrew release for alias jdoe, which still carries /kirocrew.
  • Narrowing I can argue but not confirm: input 4 was exempt at base and is newly redacted at head. The new regex captures command=kirocrew, but slash_command("jdoe") is kirocrew-jdoe. Who loses it: an operator who re-pastes a link from an older install's transcript or a saved setup note, or a fleet where an older CLI or dashboard emits the link while newer code does the redaction. That link would now create an app with the Grid-colliding command, so refusing it may be intended. It still deserves an explicit decision rather than an incidental loss. Inputs 1–3 should survive by construction, since render and validator share slash_command. Nothing here classified them.

[SCOPE-REVIEWED] 867f259

@iamwhatever
iamwhatever force-pushed the fix/11386-slack-command-per-alias branch from 6d63bdc to f249423 Compare October 9, 2026 18:29
@iamwhatever

Copy link
Copy Markdown
Contributor Author

Rebased: main moved in same-dir/import neighbours of this PR's files (docs/guides, src/kiro_crew, test/test_redaction_mirror_parity.py) since this head went green (d4c3a73 -> c241d6b); CI re-running.

@iamwhatever

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: f249423
  • What rule changed: the Slack app-create deep-link carve-out in _kirocrew_slack_app_link_alias reads the manifest's new {{COMMAND}} slot as a command group and accepts the link only when it equals slack_manifest.slash_command(alias).
  • Before -> after (what was allowed/blocked, now): before, a payload matching the template with one alias was exempt from the base64/length heuristics. After, the same, and the command slot must also equal the value derived from that alias; any other command is redacted as before. Nothing new is exempt.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): our own kirocrew manifest --url link gets redacted again (setup inconvenience). No secret path: the command is a pure function of the alias, and the alias is still scanned by the heuristics.
  • Evidence checked (which sandbox result proves it): N/A - no sandbox rule moved; test/test_security.py::TestKiroCrewSlackAppCreateLink and test/test_slack_manifest_command.py::TestDeepLinkValidator (real emitter unredacted for a 32-char mixed-case alias; mismatched command redacted).
  • No regression:
    • Tools still work (which tools/commands were run, result): kirocrew manifest --url path via cli_setup._manifest in tests prints an unredacted link plus the config set hint.
    • Backward compatible (old config / old data / old callers still work, how checked): yes; the dashboard alias kirocrew still renders /kirocrew, existing slack.command values are untouched (TestSetupWizardDefault).
    • Existing tests (which suites passed on this head): test/test_security.py::TestKiroCrewSlackAppCreateLink, test/test_security_gate_liveness.py (package line budget unchanged at 28,581 <= 28,582), test/test_slack_manifest_scopes.py, test/test_slack_manifest_command.py.
  • How to undo: revert this PR's commit; the template and validator return to the single-alias form.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=6138eef51298 wide-encoded credential file reads as a fresh install

rebutted (disproportional): the case needs a UTF-16/32 .env, no configured slack.command, and an app made with /kirocrew.
Even then the wizard only offers a default: the prompt shows it and says (must match your Slack app), and kirocrew setup --slack already prints the wide-encoding fix for that file in _setup_slack_tokens.
No new reader is added; a second encoding probe for this rare path is outside the goal.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Oct 9, 2026
@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=c448dd8c7861 Item 1, manifest default

needs-a-decision: same question as the earlier answer at #18550 (comment) — a maintainer ruling (override or RFC) on new CLI apps registering /kirocrew-<alias>.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=d11da3df683e Item 3, wizard default

needs-a-decision: same ruling as Item 1; earlier answer #18550 (comment).

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=33888ec97de3 product-shape change without accepted RFC

needs-a-decision: correct, no RFC exists; the agent will not self-override. Earlier answer #18550 (comment).

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=63ae72c879eb Item 4, undeclared prompt relabel

fixed (description): the PR body's What changed now names the Slash command name (must match your Slack app) prompt label. No code change.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=08312fedb7fa wizard re-derives the alias

needs-a-decision: real gap, already disclosed. Two fixes are possible; which one is a maintainer call:
(a) keep kirocrew as the wizard default and rely on the config set line kirocrew manifest prints;
(b) the Suggestion: kirocrew manifest saves slack.command when none is set, and the wizard default change is dropped.
Either lands in this PR once chosen.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=cd19526f6f51 let kirocrew manifest set slack.command

rebutted: kirocrew manifest prints a manifest for an app that does not exist yet, often to a file (-o) or a link opened later; writing slack.command then would stop the running install from answering its current command before the new app is installed.
the printed line lets the person switch once the app exists; a CLI that writes config when it prints is new behaviour outside the frozen goal.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=136ba873fef6 the step leaves the user without a next action

fixed in 867f259: the Settings → Slack step and manifest_command_step are removed; this PR changes no dashboard UI.
the one-click link registers /kirocrew, which the default slack.command answers, so that flow needs no step.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=170c1e8a8d28 nothing tells the user why the step appears

fixed in 867f259: the Settings → Slack step and manifest_command_step are removed; this PR changes no dashboard UI.
the one-click link registers /kirocrew, which the default slack.command answers, so that flow needs no step.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=41a301f258c8 reword the step to give the reason and the place first

fixed in 867f259: the Settings → Slack step and manifest_command_step are removed; this PR changes no dashboard UI.
the one-click link registers /kirocrew, which the default slack.command answers, so that flow needs no step.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=9ed4adbecfc9 rename the shell line

fixed in 867f259: the Settings → Slack step and manifest_command_step are removed; this PR changes no dashboard UI.
the one-click link registers /kirocrew, which the default slack.command answers, so that flow needs no step.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=7a3cd3f1b63f the step tells a working CLI install to set slack.command back

fixed in 867f259: the step is removed, so a connected install with a custom slack.command is shown nothing.
the endpoint still returns command for a caller that passes ?alias=; Settings never passes one.

@iamwhatever

Copy link
Copy Markdown
Contributor Author

@buluoray new head 867f2596b692ca21a26c8604009f1ff5eb4f1b56. The dashboard part of your blocking point is a one-field change now, with no UI step.

Why there is no step in Settings → Slack

  • Settings never sends an alias: getSlackManifest calls /api/slack/manifest bare (website/src/api/client/messaging.ts:424). So its one-click app always registers /kirocrew, which the default slack.command answers on the first try, as on main.
  • A step there could only fire when the saved slack.command is already custom, such as the kirocrew-<alias> a CLI app needs. It then told a working install to run kirocrew config set slack.command kirocrew, which breaks it (the Opus lane's finding on c94d289). The step and its string are gone; this PR touches no website/ file.

What answers the ?alias= path

  • src/kiro_crew/dashboard/handlers/messaging.py:2445: GET /api/slack/manifest returns command, the slash command its manifest registers, so a caller that passes ?alias= learns the slack.command value up front. It still writes no config.
  • test/test_slack_manifest_command.py:128: ?alias=JDoe returns kirocrew-jdoe, the manifest's one command.
  • test/test_slack_manifest_command.py:134: the request Settings makes (no alias) returns the SlackConfig default slack.command.
  • Both fail on 3f631c0d9d with KeyError: 'command'.

Non-blocking points taken, unchanged from the last head

  • src/kiro_crew/slack/scope_probe.py:39: _REINSTALL_HINT names the rename and the config line, pinned by test/test_slack_manifest_command.py:212.
  • docs/guides/slack-setup.md:161: the upgrade note says the same.

Left as they are in this PR: reading slack.command live, pinning the fail-closed None in security/exfil.py, and a warning when kirocrew manifest cuts an alias.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Oct 13, 2026
@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=4f22b9e72d4e per-alias default has no recorded decision

needs-a-decision: a maintainer ruling on the per-alias default at this head; the ruling recorded as the override on 569df44 and 3f631c0 binds those heads only.
the shape it ruled on is unchanged: only kirocrew manifest apps get /kirocrew-<alias>; the dashboard one-click app and every existing install keep /kirocrew.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=202d013ed682 CLI apps need a config step

needs-a-decision: the same ruling as Item 1, as the finding says; the step exists only because of that default.
the step is printed up front by kirocrew manifest, and a missed step is answered in Slack with an owner-only reply naming the line, plus a WARNING.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=bcd3dab95dc3 the command response field has no consumer

rebutted: the field is the human reviewer's blocking ask on this PR (return the command with the dashboard manifest), for the ?alias= path, which this PR makes render /kirocrew-<alias>.
?alias= is the endpoint's documented parameter (messaging spec), so its callers are API callers, not website/src; TestDashboardManifest pins both the alias case and the no-alias Settings case.
it is one line and writes nothing.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=bac9d0b525ed product-shape change without accepted RFC

needs-a-decision: the same ruling as Item 1; no RFC records the per-alias default, and the override on 569df44 and 3f631c0 binds those heads only.
the slack-manifest.yaml hunk is unchanged since that ruling.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=21da05a73630 the new default only works after a manual step

needs-a-decision: an earlier head defaulted the wizard to slash_command(alias), and Design flagged it there: an app made from the dashboard (/kirocrew) or with --alias X then got a default the app never registered.
writing slack.command when the manifest is printed would switch the running install before the new app exists. The maintainer's ruling (the override on 569df44 and 3f631c0) keeps the printed line; changing that is the maintainer's call.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=693ce3506a44 the Grid routing claim is untested

rebutted: issue #11386 is a field report from a Grid org: /kirocrew failed with the error "invalid_service" in channels and DMs, with the payload never reaching the gateway.
the same report says renaming to /kirocrew-<alias>, running kirocrew config set slack.command kirocrew-<alias> and restarting fixed it immediately.

@iamwhatever

Copy link
Copy Markdown
Contributor Author
  • span=d2db007342f2 let the gateway run any manifest-shaped command

needs-a-decision: the frozen Not a goal excludes changing how the gateway matches (/{slack.command} only), and the finding itself names it a maintainer call.
running every /kirocrew-* name would widen what the gateway executes beyond its one configured command, so this PR keeps the reply-only path.

@iamwhatever

Copy link
Copy Markdown
Contributor Author

/ai-review override first-principles 867f259: scoped fix for #11386 (Enterprise Grid slash-command collisions). Only apps generated by 'kirocrew manifest' get /kirocrew-; the dashboard one-click install and every existing install keep /kirocrew, so no current user is affected. This head returns the manifest's command from the dashboard endpoint, as buluoray asked; the default call is unchanged. An RFC is disproportionate for a manifest naming rule.

@github-actions

Copy link
Copy Markdown
Contributor

Human judgment recorded

@iamwhatever marked the first-principles AI finding as false positive, not applicable, or explicitly accepted for 867f2596b692ca21a26c8604009f1ff5eb4f1b56.

scoped fix for #11386 (Enterprise Grid slash-command collisions). Only apps generated by 'kirocrew manifest' get /kirocrew-; the dashboard one-click install and every existing install keep /kirocrew, so no current user is affected. This head returns the manifest's command from the dashboard endpoint, as buluoray asked; the default call is unchanged. An RFC is disproportionate for a manifest naming rule.

This decision applies only to this commit. A new push requires a new judgment.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: action required A blocking check or review needs attention labels Oct 14, 2026

@buluoray buluoray 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.

🤖 Kiro Crew Auto-Pipeline [operator: buluoray#38930179]:

APPROVE at 867f259. This supersedes my earlier REQUEST_CHANGES reviews.

Correction to my previous review: Settings → Slack does not offer an alias input. Its getSlackManifest() calls /api/slack/manifest without an alias, both on the previously reviewed head 3f631c0 and on this head. That path continues to register /kirocrew, matching the unconfigured gateway. My earlier claim that the Settings flow lets the user type an alias was incorrect.

The original upgrade blocker is addressed: a manifest-shaped command that differs from slack.command runs nothing, logs a WARNING, and gives an allowed owner an ephemeral reply with the matching config-set command and the required restart. The reinstall hint and setup guide now explain the rename before it happens. For API callers explicitly supplying ?alias=, the endpoint returns command alongside the manifest and URL without writing config. The new TestDashboardManifest cases cover the alias response and its agreement with the default gateway command.

I read the full diff and checked the actual Settings caller, manifest emitter, mismatch handling and regression-test assertions. Check-runs for this head: 91 success, 12 skipped, 0 failed, 0 pending; the separate PR Readiness commit status is success. No local tests, mutation tests or real Slack/Grid run were performed during this re-review.

Non-blocking scope and follow-ups: CLI-created apps still require the printed slack.command configuration step and, for a running gateway, restart. Dashboard-created apps retain the generic command, so their Grid collisions are not solved here. Alias case/truncation collisions are documented. The missing-command-slot fail-closed test and a truncation warning remain follow-ups, not blockers.

Auto-merge is enabled; the operator explicitly authorized this approval.

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.

Slack manifest: make slash command name unique per install (Enterprise Grid collisions)

2 participants