design-app: refusal fixture uses the slug-taken sentinel, which by spec has no Try again #1742

Closed
opened 2026-09-22 18:02:34 +00:00 by matou-build-agent · 2 comments

The failure

design-app is the only red — verdict.json reads 40 green / 1 red / 0 skip, and the leg timed out waiting for the Try again control on the failed community-app card:

"leg": "design-app", "status": "red", "ms": 233881,
"error": "a refused build offers Try again\n\nexpect(locator).toBeVisible() failed\n\nLocator: locator('[data-field=\"community-app\"][data-status=\"failed\"]').first().locator('[data-action=\"rebuild\"]')\nExpected: visible\nTimeout: 30000ms\nError: element(s) not found"

This is NOT the drive's known pairing frontier. legs.json carries no skip entries at all, and pair is green ({"leg": "pair", "status": "green", "ms": 4237}). The own-VPS carrier issue did not fire on this run.

The evidence

Everything up to the assertion passed. The a11y snapshot in artifacts/journey.idip-.../error-context.md shows the card reached failed and carried Coa's words — expectCard(dash,'failed') and toContainText(refusal) both succeeded:

- text: YOUR COMMUNITY Your community app — the build failed Coa already holds a page for this name

Note what is absent from that snapshot: no button of any kind in the card. Not a mislabelled one — zero actions rendered.

The live box (170.64.217.169, reachable; systemctl --failed empty) confirms the back end did its half correctly:

Sep 22 17:59:25 gateway idss-control-plane-start[11929]: level=INFO
  msg="community-app designed from the dashboard twin" component=control-plane slug="" state=failed
# curl -sS http://127.0.0.1:8080/api/v1/community-app
{"state":"failed","slug":"","page_url":"","submitted_at":"","last_checked_at":"",
 "reason":"Coa already holds a page for this name","downloads_url":"","platforms":[]}

The defect — the fixture picked the one reserved refusal string

The drive arms the fake Coa with:

// app/tests/e2e/journey.idip.spec.ts:1506
const refusal = 'Coa already holds a page for this name';
await coaFake.setRefusal(refusal);

That string is byte-identical to the product's slug-taken sentinel, declared in two places and asserted equal across the seam:

// packages/ui-kit/src/communityAppCard.ts:28
export const SLUG_TAKEN_MESSAGE = 'Coa already holds a page for this name';
// internal/communityapp/poll.go:202
const SlugTakenMessage = "Coa already holds a page for this name"

The resolver's failed branch checks that sentinel first and deliberately withholds the rebuild action (packages/ui-kit/src/communityAppCard.ts, case 'failed'):

// Slug-taken (spec #1495 story 18): a re-submit Coa answered slug-taken because
// the earlier submission made the page. Name it plainly and point at Coa's page
// rather than looping — NO `try again`.
if (view.reason === SLUG_TAKEN_MESSAGE) {
  return { status: 'failed', ..., detail: SLUG_TAKEN_MESSAGE,
    actions: view.pageUrl ? [{ ... data: 'app-details', label: 'View on Coa ↗' ... }] : [] };
}

Only the generic branch below it emits the control the test waits for:

{ kind: 'resubmit', data: 'rebuild', label: 'Try again' }

And because the fake refused without a page (page_url is ""), the slug-taken branch yields actions: [] — which is exactly why the a11y tree shows no button at all rather than a differently-named one.

Likely origin of the mistake: cmd/rehearsal-coa/main.go:18 uses that very sentence as its example --refuse value, so it reads like a generic sample refusal when it is in fact reserved.

Suspected layer: harness

The product is doing precisely what spec #1495 story 18 asks. verdict.json pins the run to d78a9903, the commit that introduced this assertion ("design-app proves the REFUSED half too … the card lands failed with Coa's words, and Try again carries it to pending") — so this is the new assertion's first contact with the real resolver, and it chose a refusal that routes down the no-retry path.

What plugging it needs

  1. In app/tests/e2e/journey.idip.spec.ts:1506, change refusal to an ordinary build failure that is not SLUG_TAKEN_MESSAGE — e.g. 'the Android build ran out of memory'. That routes to the generic failed branch, which renders [data-action="rebuild"], and the rest of the leg (Try again → pending, submissions().length === 0) then exercises what it was written to prove.
  2. Guard the collision so it cannot recur: import SLUG_TAKEN_MESSAGE in the spec and assert refusal !== SLUG_TAKEN_MESSAGE, or have rehearsal-coa refuse to arm that exact string without an explicit flag.
  3. Fix the misleading example in cmd/rehearsal-coa/main.go:18 — it advertises the reserved sentinel as the sample refusal.
  4. Optional follow-on, if the drive wants both halves: a second press armed with the sentinel asserting the card shows Coa's words and offers no [data-action="rebuild"] — story 18's other half, currently unproven end-to-end.

Secondary observation, not the red: with the sentinel and an empty page_url, the slug-taken card renders zero actions, leaving the operator with no next step on the panel. That matches the code as written but may be worth a product look separately.

drive 20260922T173216Z red at design-app: a refused build offers Try again expect(locator).toBeVisible() failed Locator: locator('[data-field="community-app"][data-status="failed"]').first().locator('[data-action="rebuild"]') Expected: visibl
evidence: /home/swarm/session-runner/idss/test-results/drive-idip/20260922T173216Z on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured

## The failure `design-app` is the only red — `verdict.json` reads 40 green / 1 red / **0 skip**, and the leg timed out waiting for the *Try again* control on the `failed` community-app card: ``` "leg": "design-app", "status": "red", "ms": 233881, "error": "a refused build offers Try again\n\nexpect(locator).toBeVisible() failed\n\nLocator: locator('[data-field=\"community-app\"][data-status=\"failed\"]').first().locator('[data-action=\"rebuild\"]')\nExpected: visible\nTimeout: 30000ms\nError: element(s) not found" ``` **This is NOT the drive's known pairing frontier.** `legs.json` carries no skip entries at all, and `pair` is green (`{"leg": "pair", "status": "green", "ms": 4237}`). The own-VPS carrier issue did not fire on this run. ## The evidence Everything up to the assertion passed. The a11y snapshot in `artifacts/journey.idip-.../error-context.md` shows the card reached `failed` *and* carried Coa's words — `expectCard(dash,'failed')` and `toContainText(refusal)` both succeeded: ``` - text: YOUR COMMUNITY Your community app — the build failed Coa already holds a page for this name ``` Note what is absent from that snapshot: **no button of any kind** in the card. Not a mislabelled one — zero actions rendered. The live box (170.64.217.169, reachable; `systemctl --failed` empty) confirms the back end did its half correctly: ``` Sep 22 17:59:25 gateway idss-control-plane-start[11929]: level=INFO msg="community-app designed from the dashboard twin" component=control-plane slug="" state=failed ``` ``` # curl -sS http://127.0.0.1:8080/api/v1/community-app {"state":"failed","slug":"","page_url":"","submitted_at":"","last_checked_at":"", "reason":"Coa already holds a page for this name","downloads_url":"","platforms":[]} ``` ## The defect — the fixture picked the one reserved refusal string The drive arms the fake Coa with: ```ts // app/tests/e2e/journey.idip.spec.ts:1506 const refusal = 'Coa already holds a page for this name'; await coaFake.setRefusal(refusal); ``` That string is byte-identical to the product's **slug-taken sentinel**, declared in two places and asserted equal across the seam: ```ts // packages/ui-kit/src/communityAppCard.ts:28 export const SLUG_TAKEN_MESSAGE = 'Coa already holds a page for this name'; ``` ```go // internal/communityapp/poll.go:202 const SlugTakenMessage = "Coa already holds a page for this name" ``` The resolver's `failed` branch checks that sentinel *first* and deliberately withholds the rebuild action (`packages/ui-kit/src/communityAppCard.ts`, `case 'failed'`): ```ts // Slug-taken (spec #1495 story 18): a re-submit Coa answered slug-taken because // the earlier submission made the page. Name it plainly and point at Coa's page // rather than looping — NO `try again`. if (view.reason === SLUG_TAKEN_MESSAGE) { return { status: 'failed', ..., detail: SLUG_TAKEN_MESSAGE, actions: view.pageUrl ? [{ ... data: 'app-details', label: 'View on Coa ↗' ... }] : [] }; } ``` Only the generic branch below it emits the control the test waits for: ```ts { kind: 'resubmit', data: 'rebuild', label: 'Try again' } ``` And because the fake refused without a page (`page_url` is `""`), the slug-taken branch yields `actions: []` — which is exactly why the a11y tree shows no button at all rather than a differently-named one. Likely origin of the mistake: `cmd/rehearsal-coa/main.go:18` uses that very sentence as its example `--refuse` value, so it reads like a generic sample refusal when it is in fact reserved. ## Suspected layer: **harness** The product is doing precisely what spec #1495 story 18 asks. `verdict.json` pins the run to `d78a9903`, the commit that *introduced* this assertion ("design-app proves the REFUSED half too … the card lands failed with Coa's words, and Try again carries it to pending") — so this is the new assertion's first contact with the real resolver, and it chose a refusal that routes down the no-retry path. ## What plugging it needs 1. In `app/tests/e2e/journey.idip.spec.ts:1506`, change `refusal` to an ordinary build failure that is **not** `SLUG_TAKEN_MESSAGE` — e.g. `'the Android build ran out of memory'`. That routes to the generic `failed` branch, which renders `[data-action="rebuild"]`, and the rest of the leg (Try again → `pending`, `submissions().length === 0`) then exercises what it was written to prove. 2. Guard the collision so it cannot recur: import `SLUG_TAKEN_MESSAGE` in the spec and assert `refusal !== SLUG_TAKEN_MESSAGE`, or have `rehearsal-coa` refuse to arm that exact string without an explicit flag. 3. Fix the misleading example in `cmd/rehearsal-coa/main.go:18` — it advertises the reserved sentinel as the sample refusal. 4. Optional follow-on, if the drive wants both halves: a second press armed *with* the sentinel asserting the card shows Coa's words and offers **no** `[data-action="rebuild"]` — story 18's other half, currently unproven end-to-end. Secondary observation, not the red: with the sentinel *and* an empty `page_url`, the slug-taken card renders zero actions, leaving the operator with no next step on the panel. That matches the code as written but may be worth a product look separately. drive `20260922T173216Z` red at `design-app`: `a refused build offers Try again expect(locator).toBeVisible() failed Locator: locator('[data-field="community-app"][data-status="failed"]').first().locator('[data-action="rebuild"]') Expected: visibl` evidence: `/home/swarm/session-runner/idss/test-results/drive-idip/20260922T173216Z` on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured <!-- rehearsal-sig: fc7b669e5189 -->
Author
Member

swarm-claim host=matou-dev-server-01 run=30298
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=30298 (automated multi-host claim — lowest live claim id works this ticket)
Author
Member

close-report for #1742 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 1742,
  "status": "success",
  "commits": [
    "0cbf99ca"
  ],
  "changed_files": [
    "STATUS.md",
    "app/tests/e2e/fixtures/coaPairing.ts",
    "cmd/rehearsal-coa/coa.go",
    "cmd/rehearsal-coa/coa_test.go",
    "cmd/rehearsal-coa/main.go"
  ],
  "tests": [
    {
      "command": "nix develop .#go-ci -c go test ./cmd/rehearsal-coa/ ./internal/communityapp/ ./internal/wireconvention/",
      "exit_code": 0
    },
    {
      "command": "nix develop .#go-ci -c go vet ./cmd/rehearsal-coa/",
      "exit_code": 0
    },
    {
      "command": "nix develop .#go-ci -c golangci-lint run ./cmd/rehearsal-coa/",
      "exit_code": 0
    },
    {
      "command": "node_modules/.bin/vitest run tests/e2e/fixtures/coaPairing.test.ts",
      "exit_code": 0
    },
    {
      "command": "node_modules/.bin/vue-tsc -p tsconfig.json --noEmit",
      "exit_code": 0
    }
  ],
  "criteria": {
    "The primary red (design-app arms SLUG_TAKEN_MESSAGE and reds on the missing Try again) is resolved": "Item 1 fixed live in 77b25f56 (pre-existing); this ticket closes the footgun behind it so it cannot recur",
    "Guard the collision so it cannot recur (item 2)": "cmd/rehearsal-coa/coa.go guardReservedRefusal refuses to arm communityapp.SlugTakenMessage bare over /refuse (422) or --refuse (exit 2); proven by TestFakeCoa_RefuseRouteGuardsTheSlugTakenSentinel and TestGuardReservedRefusal",
    "Fix the misleading --refuse example (item 3)": "cmd/rehearsal-coa/main.go:18 usage + the --refuse flag doc now show a retryable build failure, and note --refuse-slug-taken for the reserved sentinel",
    "The deliberate story-18 half stays drivable": "slugTaken:true (/refuse) / --refuse-slug-taken (flag) / setRefusal(reason,{slugTaken}) acknowledge the sentinel; TestFakeCoa_RefusalIsArmedAndDisarmedAtRuntime carries the ack and stays green"
  },
  "summary": "cmd/rehearsal-coa now refuses to arm the reserved slug-taken sentinel as a refusal without an explicit acknowledgement, closing the #1742 footgun at the single choke point every drive leg funnels through.",
  "blockers": []
}
**close-report** for #1742 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 1742, "status": "success", "commits": [ "0cbf99ca" ], "changed_files": [ "STATUS.md", "app/tests/e2e/fixtures/coaPairing.ts", "cmd/rehearsal-coa/coa.go", "cmd/rehearsal-coa/coa_test.go", "cmd/rehearsal-coa/main.go" ], "tests": [ { "command": "nix develop .#go-ci -c go test ./cmd/rehearsal-coa/ ./internal/communityapp/ ./internal/wireconvention/", "exit_code": 0 }, { "command": "nix develop .#go-ci -c go vet ./cmd/rehearsal-coa/", "exit_code": 0 }, { "command": "nix develop .#go-ci -c golangci-lint run ./cmd/rehearsal-coa/", "exit_code": 0 }, { "command": "node_modules/.bin/vitest run tests/e2e/fixtures/coaPairing.test.ts", "exit_code": 0 }, { "command": "node_modules/.bin/vue-tsc -p tsconfig.json --noEmit", "exit_code": 0 } ], "criteria": { "The primary red (design-app arms SLUG_TAKEN_MESSAGE and reds on the missing Try again) is resolved": "Item 1 fixed live in 77b25f56 (pre-existing); this ticket closes the footgun behind it so it cannot recur", "Guard the collision so it cannot recur (item 2)": "cmd/rehearsal-coa/coa.go guardReservedRefusal refuses to arm communityapp.SlugTakenMessage bare over /refuse (422) or --refuse (exit 2); proven by TestFakeCoa_RefuseRouteGuardsTheSlugTakenSentinel and TestGuardReservedRefusal", "Fix the misleading --refuse example (item 3)": "cmd/rehearsal-coa/main.go:18 usage + the --refuse flag doc now show a retryable build failure, and note --refuse-slug-taken for the reserved sentinel", "The deliberate story-18 half stays drivable": "slugTaken:true (/refuse) / --refuse-slug-taken (flag) / setRefusal(reason,{slugTaken}) acknowledge the sentinel; TestFakeCoa_RefusalIsArmedAndDisarmedAtRuntime carries the ack and stays green" }, "summary": "cmd/rehearsal-coa now refuses to arm the reserved slug-taken sentinel as a refusal without an explicit acknowledgement, closing the #1742 footgun at the single choke point every drive leg funnels through.", "blockers": [] } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#1742
No description provided.