From 8f7a84c2ee7bc4f5d2f22d64b0f45bb18c29bcaa Mon Sep 17 00:00:00 2001 From: "dam-application[bot]" <280654635+dam-application[bot]@users.noreply.github.com> Date: Thu, 19 Nov 2026 12:25:15 +0000 Subject: [PATCH] fix: no Slack post when a pull request waits for a review in its Environment (6.18.1) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Removes the slack_ui_review key and the 🎨 notify line park printed for it. Co-Authored-By: Claude Opus 5.5 --- CHANGELOG.md | 12 ++++++++++++ CLAUDE.md | 3 +-- ONBOARDING.md | 7 ++----- VERSION | 2 +- app/src/developer/kit.ts | 2 +- app/src/developer/run-state.ts | 21 +++------------------ app/src/developer/verify.ts | 15 --------------- app/test/run-state.test.ts | 27 --------------------------- docs/notify.md | 9 --------- 9 files changed, 20 insertions(+), 78 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 529ebc8..5d9d8f5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,18 @@ Applying the kit never touches an agent already created from it, so an instance crosses a version only when its operator walks it through these steps, in the direct session. +## 6.18.1 — 2026-11-19 + +**No more 🎨 post when a pull request waits for a review in its Environment.** +`park` no longer prints a `notify:` line for a `label_ui_review` pull request +out of draft, and the `slack_ui_review` key is gone. `label_ui_review` still +decides which Environments are taken back last +([environments.md](docs/environments.md)). + +**Upgrade:** remove the `- slack_ui_review: …` line from `work/CONFIG.md`, or +`verify-onboarding.sh` fails it as an unknown key; operator only, in the direct +session. + ## 6.18.0 — 2026-11-13 **Who hands an issue off on GitHub can hear of it in a Slack direct message.** diff --git a/CLAUDE.md b/CLAUDE.md index 83bb7b5..e40cd1d 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -80,8 +80,7 @@ a line in any other shape is invisible, not wrong. [`docs/slack.md`](docs/slack.md)). `skill_grill`, `skill_file_issue` — the repository's skills for those; missing: `.agents/defaults/`. `slack_handoff` — who there may file or hand off an issue: `anyone` (agents too), `people`, or - `off`; missing: anyone. `slack_ui_review` — the chat told, once, of each - `label_ui_review` pull request out of draft; missing: none. `slack_automerge` + `off`; missing: anyone. `slack_automerge` — who there may ask for auto-merge on a pull request of yours: `off`, `people`, or Slack user ids; missing: off. `slack_people` — `login=` pairs: who handed an issue off on GitHub hears of its ✅ ❓ 🛑 in a diff --git a/ONBOARDING.md b/ONBOARDING.md index 6227bef..9e7ebc1 100644 --- a/ONBOARDING.md +++ b/ONBOARDING.md @@ -141,9 +141,7 @@ confirming or correcting rather than composing from nothing. sub-issues it files with the hand-off label ([`docs/slack.md`](docs/slack.md)). And hand-offs: asked there to implement an issue, it adds the hand-off label itself, and asked to file an issue, it files it — ask who may, `anyone` in the channel (bots too, the default), - `people` or `off`, and record it as `slack_handoff`. With `label_ui_review` - set, offer a chat told of each such pull request once it is out of draft, - for whoever reviews it in its Environment: `slack_ui_review`. + `people` or `off`, and record it as `slack_handoff`. Ask, too, whether anyone there may ask for auto-merge on your pull requests — the default is no: `off`, `people`, or the Slack user ids of who may, from `describe_channel_users`; whoever it names may in effect merge. @@ -220,7 +218,6 @@ that is not one of them fails verification, because nothing would ever read it: - work_account: - slack_channel: C0123ABCD - slack_handoff: anyone -- slack_ui_review: C0123ABCD - slack_automerge: off - slack_people: alice=U0123ABCD bob=U0456EFGH - skill_grill: grill-me @@ -239,7 +236,7 @@ Interactive, leave out `label_handoff`, `label_failed`, `label_needs_info`, no demo, `demo_environment`; with neither check, or no path that needs one, `verify_required_paths`; with no Environment at all, `label_ui_review`; with no -review label, `label_review`; with no backup, leave out `work_repo` and `work_account`; when the active account reaches it, `work_account`; with no Slack, leave out `slack_channel`, `slack_handoff`, `slack_ui_review`, `slack_automerge` and `slack_people`; with nobody to tell directly, `slack_people`; +review label, `label_review`; with no backup, leave out `work_repo` and `work_account`; when the active account reaches it, `work_account`; with no Slack, leave out `slack_channel`, `slack_handoff`, `slack_automerge` and `slack_people`; with nobody to tell directly, `slack_people`; with every slot open, `slots_closed`; for the default grill skills, `skill_grill` and `skill_file_issue`; leave `repos_also` out when the work never leaves `repo`; leave `prune` and `prune_below_gb` out when builds leave little behind. diff --git a/VERSION b/VERSION index 1b386a5..2016ec3 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -6.18.0 +6.18.1 diff --git a/app/src/developer/kit.ts b/app/src/developer/kit.ts index b0e9b35..e6f96b4 100644 --- a/app/src/developer/kit.ts +++ b/app/src/developer/kit.ts @@ -28,7 +28,7 @@ export const ITEM_KEYS = [ "babysat_out", // the pull request a Slack "ready to merge" post was asked for, so it is asked once "notified", - // the pull requests a Slack "review it in its Environment" post was asked for, so it is asked once + // retired: nothing writes it; kept so an older item file still reads clean "ui_notified", // the last required check recorded for the item: " " "checked", diff --git a/app/src/developer/run-state.ts b/app/src/developer/run-state.ts index 86517e9..f31193b 100644 --- a/app/src/developer/run-state.ts +++ b/app/src/developer/run-state.ts @@ -705,20 +705,13 @@ class RunState { // where the pull requests stand decides the state: approved, every open one, is a wait for the merge let approved = true; let open = 0; - // out of draft and labelled label_ui_review: a person reviews it in its Environment - const ui: PrRef[] = []; - const uiLabel = this.kit.labelUiReview; for (const ref of refs) { - const view = (await this.deps.github.prView( - this.kit.host, - ref.slug, - ref.number, - "state,reviewDecision,isDraft,labels", - )) as { state?: string; reviewDecision?: string; isDraft?: boolean; labels?: { name?: string }[] } | undefined; + const view = (await this.deps.github.prView(this.kit.host, ref.slug, ref.number, "state,reviewDecision")) as + | { state?: string; reviewDecision?: string } + | undefined; if (view?.state === "MERGED" || view?.state === "CLOSED") continue; open++; if (view?.reviewDecision !== "APPROVED") approved = false; - if (uiLabel && view?.isDraft === false && (view.labels ?? []).some((l) => l.name === uiLabel)) ui.push(ref); } if (open === 0) { this.say( @@ -758,14 +751,6 @@ class RunState { await this.tellRequester(item, `that ${labels} is ready to merge`); this.writeItem(item, { notified: prs }); } - const uiChat = this.kit.cfg.get("slack_ui_review"); - const uiPrs = ui.map((x) => recordRef(x, this.kit.slug)).join(" "); - if (uiChat && uiPrs && this.itemKey(item, "ui_notified") !== uiPrs) { - this.say( - `notify: post 🎨 that ${ui.map((x) => labelRef(x, this.kit.slug)).join(" ")} waits for a review in its Environment, top-level to slack_ui_review ${uiChat} (docs/notify.md → A review in the Environment)`, - ); - this.writeItem(item, { ui_notified: uiPrs }); - } this.out(`parked #${item} (${state}): the slot and the exclusive lock are free; the item stays yours.`); if (watched) { this.out("Now end the turn, with nothing left running: the precheck watches it."); diff --git a/app/src/developer/verify.ts b/app/src/developer/verify.ts index 1fc346b..b94d489 100644 --- a/app/src/developer/verify.ts +++ b/app/src/developer/verify.ts @@ -54,7 +54,6 @@ export const KNOWN = [ "work_account", "slack_channel", "slack_handoff", - "slack_ui_review", "slack_automerge", "slack_people", "schedules", @@ -149,20 +148,6 @@ function configChecks(kit: Kit, r: Report): void { `'${handoff}' is not anyone, people or off`, "write one of them, or leave it out for anyone", ); - const uiChat = cfg.get("slack_ui_review"); - if (!uiChat) - r.ok("config.slack_ui_review", "unset — no post when a pull request waits for a review in its Environment"); - else if (!/^[A-Z0-9]+$/.test(uiChat)) - r.fail( - "config.slack_ui_review", - `'${uiChat}' is not a chat id`, - "the id describe_channel lists for it, e.g. C0123ABCD, not #name", - ); - else if (!cfg.get("label_ui_review")) - r.warn("config.slack_ui_review", "set, but label_ui_review is not — nothing marks a pull request to post"); - else - r.ok("config.slack_ui_review", `${uiChat} hears of each ${cfg.get("label_ui_review")} pull request out of draft`); - const automerge = cfg.get("slack_automerge"); const ids = automerge.split(/[\s,]+/).filter(Boolean); if (["", "off", "people"].includes(automerge) || ids.every((id) => /^[UW][A-Z0-9]+$/.test(id))) { diff --git a/app/test/run-state.test.ts b/app/test/run-state.test.ts index 97d11ed..5a7621a 100644 --- a/app/test/run-state.test.ts +++ b/app/test/run-state.test.ts @@ -158,33 +158,6 @@ test("with slack_people set, who handed the issue off on GitHub hears of its mom assert.doesNotMatch(r.err, /notify:/, "no pair for carol: nobody to tell"); })); -test("with slack_ui_review set, park says to post a label_ui_review pull request out of draft, once", () => - inSandbox(async (s) => { - world(s); - s.originCheckout(); - s.github.on(PULL, PULL21); - s.config("- label_ui_review: qa:design\n- slack_ui_review: C0456EFGH"); - s.github.prViews = [{ state: "OPEN", reviewDecision: "", isDraft: true, labels: [{ name: "qa:design" }] }]; - await as(s, "sess-a", "start", "7", "feat/7"); - let r = await as(s, "sess-a", "park", "21"); - assert.equal(r.rc, 0, r.err); - assert.doesNotMatch(r.err, /notify:/, "a draft waits for nobody"); - s.github.prViews = [{ state: "OPEN", reviewDecision: "", isDraft: false, labels: [{ name: "other" }] }]; - await as(s, "sess-a", "start", "7", "feat/7"); - r = await as(s, "sess-a", "park", "21"); - assert.doesNotMatch(r.err, /notify:/, "not labelled: not reviewed in its Environment"); - s.github.prViews = [{ state: "OPEN", reviewDecision: "", isDraft: false, labels: [{ name: "qa:design" }] }]; - await as(s, "sess-a", "start", "7", "feat/7"); - r = await as(s, "sess-a", "park", "21"); - assert.match( - r.err, - /notify: post 🎨 that #21 waits for a review in its Environment, top-level to slack_ui_review C0456EFGH/, - ); - await as(s, "sess-a", "start", "7", "feat/7"); - r = await as(s, "sess-a", "park", "21"); - assert.doesNotMatch(r.err, /notify:/, "said once for the same pull request"); - })); - test("a thread the item already has in Slack takes its posts, and only one the author left in that chat", () => inSandbox(async (s) => { world(s); diff --git a/docs/notify.md b/docs/notify.md index 59cdd97..8f2c121 100644 --- a/docs/notify.md +++ b/docs/notify.md @@ -15,7 +15,6 @@ direct message has a key of its own (below). | A question for a person | `finish needs-info` | ❓ `#` needs info — the question, in one line | | Cannot go on | `finish blocked` | 🛑 `#` is blocked — what fails, in one line | | A required check that did not pass | `checked … fail\|skipped`, once a week per cause | 🚨 `#`: `` failed / did not run — the cause, in one line | -| A pull request labelled `label_ui_review`, out of draft | `park`, once per set of pull requests | 🎨 `#` waits for a review in its Environment — ``, its Environment's URL — to `slack_ui_review` | | Every Environment held, none to take back, with `verify_environment` | `room`, once a day per set of pull requests | 🧱 `<repo>#<n>` waits for an Environment — then each pull request holding one: review it, or merge it | | Weekly audit | the audit's report | the report's header and its **Action needed** lines; a 🚨 first when it has a red line | @@ -41,14 +40,6 @@ Nothing else: no claims, pushes, review rounds, `nothing` ticks or a pull request closed without merging. Each post carries the link to the issue or pull request, mentions no one, and repeats nothing the link already says. -## A review in the Environment - -Off unless `slack_ui_review` names a chat; it does not need `slack_channel`. -Posted when `park` prints its `notify:` line, top-level in that chat, not in -the item's thread: who reviews it there is the person to reach. One line per -pull request — its link, its title and its Environment's URL -([environments.md](environments.md)) — and nothing is recorded on GitHub. - ## Every Environment held Posted when `room` prints its `notify:` line, top-level in `slack_channel`, not