@codyswann/lisa 2.44.0 → 2.46.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/plugins/lisa/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa/skills/confluence-prd-intake/SKILL.md +81 -6
- package/plugins/lisa/skills/github-prd-intake/SKILL.md +110 -4
- package/plugins/lisa/skills/linear-prd-intake/SKILL.md +80 -6
- package/plugins/lisa/skills/notion-prd-intake/SKILL.md +75 -4
- package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
- package/plugins/src/base/skills/confluence-prd-intake/SKILL.md +81 -6
- package/plugins/src/base/skills/github-prd-intake/SKILL.md +110 -4
- package/plugins/src/base/skills/linear-prd-intake/SKILL.md +80 -6
- package/plugins/src/base/skills/notion-prd-intake/SKILL.md +75 -4
|
@@ -37,10 +37,23 @@ BLOCKED=$(read_role blocked "Blocked")
|
|
|
37
37
|
TICKETED=$(read_role ticketed "Ticketed")
|
|
38
38
|
SHIPPED=$(read_role shipped "Shipped")
|
|
39
39
|
STATUS_PROP=$(jq -r '.notion.statusProperty // "Status"' .lisa.config.json 2>/dev/null)
|
|
40
|
+
|
|
41
|
+
# Resolve a boolean rollup flag. Local overrides global per-key; default when unset.
|
|
42
|
+
read_rollup_flag() {
|
|
43
|
+
local key="$1" default="$2"
|
|
44
|
+
local local_v global_v
|
|
45
|
+
local_v=$(jq -r ".notion.rollup.${key} // empty" .lisa.config.local.json 2>/dev/null)
|
|
46
|
+
global_v=$(jq -r ".notion.rollup.${key} // empty" .lisa.config.json 2>/dev/null)
|
|
47
|
+
echo "${local_v:-${global_v:-$default}}"
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
CLOSE_ON_SHIPPED=$(read_rollup_flag closeOnShipped false)
|
|
40
51
|
```
|
|
41
52
|
|
|
42
53
|
In prose below, the role names refer to the resolved values: e.g. "the `ready` status" means whatever `notion.values.ready` resolves to (default: `Ready`).
|
|
43
54
|
|
|
55
|
+
This skill shares its PRD closure rollup phase (3f) with `lisa:github-prd-intake`, `lisa:linear-prd-intake`, and `lisa:confluence-prd-intake`. The phases, gates, comment templates, and rollup behavior are identical across all four intake skills — only the vendor surface differs. Keep all four behaviorally aligned: when changing intake logic — including the rollup phase — change them together. The **PRD closure rollup phase (3f)** transitions a `$TICKETED` PRD to `$SHIPPED` (and optionally archives it) once all its generated top-level work is terminal, per the `prd-lifecycle-rollup` rule; this is the Notion leg of the same vendor-neutral rollup (LPC-1.3 #584), using the documented generated-work section since Notion has no native ticket hierarchy.
|
|
56
|
+
|
|
44
57
|
## Confirmation policy
|
|
45
58
|
|
|
46
59
|
Do NOT ask the caller whether to proceed. Once invoked with a database URL, run the cycle to completion — claim, validate, branch to `blocked` or `ticketed`, write the summary. The caller (a human or a cron) has already authorized the run by invoking the skill; re-prompting defeats the purpose of a background batch.
|
|
@@ -67,7 +80,7 @@ draft → ready → in_review → blocked | ticketed → shipped
|
|
|
67
80
|
(product) (us) (us) (product)
|
|
68
81
|
```
|
|
69
82
|
|
|
70
|
-
This skill
|
|
83
|
+
This skill transitions `ready → in_review`, then `in_review → blocked` or `in_review → ticketed`, then (via the rollup phase 3f) `ticketed → shipped`. It never touches `draft` — that status is owned by product. The `shipped` status is set by this skill's **rollup phase (3f)** when, and only when, the PRD's generated top-level work is all terminal — per the `prd-lifecycle-rollup` rule; product may also set it by hand. Rollup never advances a PRD to `shipped` on partial completion, and never archives a PRD page unless `notion.rollup.closeOnShipped` is configured `true` (default `false` → set `$SHIPPED`, leave the page active).
|
|
71
84
|
|
|
72
85
|
## Phases
|
|
73
86
|
|
|
@@ -226,6 +239,61 @@ The access skill resolves a `prd_anchor` substring to the matching block ID by p
|
|
|
226
239
|
|
|
227
240
|
Move to the next ready PRD. One PRD failing does not affect others.
|
|
228
241
|
|
|
242
|
+
#### 3f. PRD closure rollup (config-gated)
|
|
243
|
+
|
|
244
|
+
A PRD's lifecycle terminal state (`shipped`) is **derived** from whether the work it generated is done — it is never set by hand here on its own authority. This phase implements the Notion leg of that derivation, per the `prd-lifecycle-rollup` rule (cite it by slug; do not restate its taxonomy or terminal-state semantics here). It is behaviorally identical to `lisa:github-prd-intake`'s Phase 3f — only the vendor surface (a Notion status property via `lisa:notion-access` + the documented generated-work section) differs from GitHub's (issue close + labels via `gh`).
|
|
245
|
+
|
|
246
|
+
Rollup runs over PRD pages that are already `$TICKETED` (the only state from which a PRD can ship): the freshly-ticketed PRD from Phase 3c, and — because rollup also catches PRDs whose children finished in a *later* cycle — every page currently in `$STATUS_PROP = $TICKETED` (re-query the database with operation `query-database` filtered on the ticketed status). Process each independently; one PRD never blocks another's rollup.
|
|
247
|
+
|
|
248
|
+
##### 3f.0 Resolve closure config
|
|
249
|
+
|
|
250
|
+
Closure is gated on `notion.rollup.closeOnShipped` (default `false`), resolved via `read_rollup_flag` (defined in the Workflow resolution block, same local-overrides-global precedence the status values use):
|
|
251
|
+
|
|
252
|
+
```bash
|
|
253
|
+
CLOSE_ON_SHIPPED=$(read_rollup_flag closeOnShipped false)
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
When `false` (the default), rollup sets `$STATUS_PROP = $SHIPPED` but leaves the page **active** for a human to archive. When `true`, rollup also archives the page (where Notion supports archival) after the `shipped` transition. Closure NEVER happens before all generated top-level work is terminal (`prd-lifecycle-rollup` rule; PRD #525 non-goal).
|
|
257
|
+
|
|
258
|
+
##### 3f.1 Idempotency guard (no-op if already shipped)
|
|
259
|
+
|
|
260
|
+
Rollup is keyed by the PRD's current state. If the PRD already has `$STATUS_PROP = $SHIPPED` (and is already archived, when `$CLOSE_ON_SHIPPED` is `true`), it is a **no-op** — do not re-transition, do not re-archive, do not re-comment. Record it as `already shipped (no-op)` in the cycle summary and move on. This is what makes re-running intake safe.
|
|
261
|
+
|
|
262
|
+
##### 3f.2 Read the generated top-level child set
|
|
263
|
+
|
|
264
|
+
Read the PRD's **generated top-level work** — its created Epics and any top-level Stories created directly under it, **excluding** leaf Sub-tasks and any Story nested under a generated Epic (`prd-lifecycle-rollup` rule, generated-top-level-work contract). Notion has **no native ticket hierarchy**, so the child set comes from the documented section only:
|
|
265
|
+
|
|
266
|
+
1. **Documented `## Tickets` section (primary and only source).** Parse the machine-readable generated-work section `lisa:prd-backlink` writes to the PRD body (`## Tickets`, alias `## Generated Work`; see #582) by invoking `lisa:notion-access` operation `read-page` on the PRD. Top-level children are the `### <Epic key>: <title>` group headers' first line (`- [<ref>](<url>) — Epic`) plus any top-level Story listed directly under `### Unparented items`. Lines nested deeper (` - ... — Story:` under an Epic, ` - ... — Sub-task:`) are descendants, NOT top-level children — skip them.
|
|
267
|
+
|
|
268
|
+
Dedupe the resulting child set by **child-ref identity** — the destination ticket ref recorded in each generated-work entry (the entry is keyed by that ref, not by list position) — per the `prd-lifecycle-rollup` idempotency dedupe key. If the section yields no child (the PRD generated nothing, or the relationship was never recorded), record `no generated top-level children — rollup skipped` and leave the PRD as `$TICKETED`; do not ship an empty PRD.
|
|
269
|
+
|
|
270
|
+
##### 3f.3 Apply the terminal-state predicate
|
|
271
|
+
|
|
272
|
+
For each top-level child, classify per the `prd-lifecycle-rollup` Confluence/Notion predicate:
|
|
273
|
+
|
|
274
|
+
- **Terminal (shipped).** The documented generated-work entry for the child is marked **done** in the PRD's machine-readable section (the durable equivalent of a closed ticket, since Notion has no native ticket state). A child Epic is terminal only when it has itself rolled up to its own terminal state per `leaf-only-lifecycle` — read the child's own recorded state; do not re-derive it from its leaves here.
|
|
275
|
+
- **Terminal-but-dropped.** The entry is marked won't-do / canceled. Like a not-planned leaf, it does not hold the PRD open and is excluded from the shipped set.
|
|
276
|
+
- **Incomplete / blocked.** Anything else: the entry is not yet marked done. Holds the PRD open.
|
|
277
|
+
|
|
278
|
+
The set of **required** children for the all-terminal check is the top-level children minus the terminal-but-dropped ones.
|
|
279
|
+
|
|
280
|
+
##### 3f.4 Branch on the rollup verdict
|
|
281
|
+
|
|
282
|
+
**All required children terminal** (every required top-level child is terminal; at least one required child exists):
|
|
283
|
+
|
|
284
|
+
1. Set `$STATUS_PROP = $SHIPPED` by invoking `lisa:notion-access` operation `write-page` with payload `{ "id": "<PRD-page-id>", "properties": { "<STATUS_PROP>": { "status": { "name": "<SHIPPED>" } } } }` (use `"select"` instead of `"status"` if the property is a select).
|
|
285
|
+
2. **If `$CLOSE_ON_SHIPPED` is `true`**, archive the PRD page via `lisa:notion-access` (set `archived: true` where supported). When `false`, leave it active.
|
|
286
|
+
3. Post a short rollup Notion comment naming the terminal child set and (when dropped children exist) the dropped set, so the audit trail records *why* the PRD shipped. Lead with `"Shipped by Claude — all generated top-level work is complete."`
|
|
287
|
+
|
|
288
|
+
**Any required child incomplete / blocked**:
|
|
289
|
+
|
|
290
|
+
1. Leave `$STATUS_PROP = $TICKETED` and leave the page **active**. Do NOT set `$SHIPPED`. Do NOT archive.
|
|
291
|
+
2. Report the incomplete child set — both in the cycle summary and, when at least one cycle has previously ticketed this PRD, as a single advisory Notion comment listing the still-open children (`- <ref> "<title>" — <state>`), so product can see what's blocking the rollup. Keep it idempotent: regenerate the advisory rather than appending a fresh one each cycle.
|
|
292
|
+
|
|
293
|
+
##### 3f.5 Rollup cites the rule
|
|
294
|
+
|
|
295
|
+
This phase implements exactly one PRD-lifecycle hop — `$TICKETED → $SHIPPED` — and the optional config-gated archive that follows it. All terminal-state semantics, the generated-top-level-work boundary, and the dedupe-by-child-ref idempotency come from the `prd-lifecycle-rollup` rule; this skill is its Notion implementation, not a second source of truth.
|
|
296
|
+
|
|
229
297
|
### Phase 4 — Summary report
|
|
230
298
|
|
|
231
299
|
After processing every ready PRD, emit a summary:
|
|
@@ -254,9 +322,10 @@ Print to the agent's output. Do not write this summary to Notion or the destinat
|
|
|
254
322
|
## Idempotency & safety
|
|
255
323
|
|
|
256
324
|
- **Single-cycle scope**: this skill processes the ready set as it exists at the start of Phase 2. New ready PRDs added mid-cycle are picked up next run.
|
|
257
|
-
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:notion-to-tracker` (which delegates to `lisa:tracker-write`), and only ever changes the Notion status property to `$IN_REVIEW`, `$BLOCKED`, or `$
|
|
325
|
+
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:notion-to-tracker` (which delegates to `lisa:tracker-write`), and only ever changes the Notion status property to `$IN_REVIEW`, `$BLOCKED`, `$TICKETED`, or `$SHIPPED` (the last via the rollup phase 3f only). It never edits PRD content, never touches `$DRAFT`, never deletes pages. It sets `$SHIPPED` and may archive the PRD page **only** through the config-gated rollup phase (3f).
|
|
258
326
|
- **Claim-first ordering**: the status flip to `$IN_REVIEW` is set BEFORE validation runs, so a re-entrant call won't double-process.
|
|
259
327
|
- **Failure isolation**: an exception processing one PRD must not stop the cycle. Catch, record under "Errors" in the summary, continue to the next PRD. The PRD that errored is left in `$IN_REVIEW` — the human investigates from there.
|
|
328
|
+
- **Rollup idempotency**: rollup (Phase 3f) is a no-op on a PRD already in `$STATUS_PROP = $SHIPPED` (and already archived when `closeOnShipped` is `true`) — no duplicate transition, no duplicate archive, no duplicate comment. The all-terminal condition is a pure function of the children's current states (deduped by child-ref identity), so recomputing it is safe to re-run. Archival NEVER precedes the all-terminal condition.
|
|
260
329
|
|
|
261
330
|
## Configuration
|
|
262
331
|
|
|
@@ -273,7 +342,8 @@ This skill reads project configuration from `.lisa.config.json` (with `.lisa.con
|
|
|
273
342
|
| `notion.values.in_review` | `In Review` | Value the agent sets on claim |
|
|
274
343
|
| `notion.values.blocked` | `Blocked` | Value the agent sets on validation failure |
|
|
275
344
|
| `notion.values.ticketed` | `Ticketed` | Value the agent sets on success |
|
|
276
|
-
| `notion.values.shipped` | `Shipped` | Value
|
|
345
|
+
| `notion.values.shipped` | `Shipped` | Value the rollup phase (3f) sets when all generated top-level work is terminal; product may also set it by hand |
|
|
346
|
+
| `notion.rollup.closeOnShipped` | `false` | When `true`, rollup archives the PRD page after the `$SHIPPED` transition; when `false`, sets `$SHIPPED` and leaves the page active |
|
|
277
347
|
|
|
278
348
|
### From environment variables
|
|
279
349
|
|
|
@@ -286,7 +356,8 @@ This skill reads project configuration from `.lisa.config.json` (with `.lisa.con
|
|
|
286
356
|
## Rules
|
|
287
357
|
|
|
288
358
|
- Never write to the destination tracker outside of `lisa:notion-to-tracker` → `lisa:tracker-write`. The validator's verdict gates progress; bypassing it produces broken tickets.
|
|
289
|
-
- Never set the Notion status to a value this skill doesn't own (`$IN_REVIEW`, `$BLOCKED`, `$TICKETED`). Product owns `$DRAFT
|
|
359
|
+
- Never set the Notion status to a value this skill doesn't own (`$IN_REVIEW`, `$BLOCKED`, `$TICKETED`, and `$SHIPPED` via the rollup phase only). Product owns `$DRAFT` and `$READY`; product and the rollup phase (3f) both set `$SHIPPED`.
|
|
360
|
+
- Set `$SHIPPED` (and archive the PRD page when `closeOnShipped` is configured) only from the rollup phase, and only when all generated top-level children are terminal per the `prd-lifecycle-rollup` rule. Never ship or archive on partial completion.
|
|
290
361
|
- Never edit the PRD's body. Communication with product happens only through Notion comments.
|
|
291
362
|
- Never post a single page-level dump of all gate failures. One comment per `prd_anchor` group (or one page-level summary for unanchored failures only). The audience is product, not engineers — comments must be block-anchored, categorized, plain-language, and contain a concrete recommendation. See Phase 3c.3 for the required template and Phase 3c.5 for forbidden language.
|
|
292
363
|
- Never include a gate ID, internal skill name, or engineering shorthand in a Notion comment body. If the validator's `what` or `recommendation` field uses one, paraphrase before posting.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.46.0",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, for Claude Code and Codex",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lisa-openclaw",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.46.0",
|
|
4
4
|
"description": "Connect staff roles to Telegram or Slack via OpenClaw — facilitator/specialist hub-and-spoke routing and repo-coding topics, across Claude and Codex.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Cody Swann"
|
|
@@ -59,11 +59,26 @@ current_role_for_prd() {
|
|
|
59
59
|
done
|
|
60
60
|
echo "unknown"
|
|
61
61
|
}
|
|
62
|
+
|
|
63
|
+
# Resolve a boolean rollup flag. Local overrides global per-key; default when unset.
|
|
64
|
+
# NOTE: Confluence rollup config lives under `confluence.rollup` (NOT
|
|
65
|
+
# `confluence.parents.rollup`) — see the config-resolution rule.
|
|
66
|
+
read_rollup_flag() {
|
|
67
|
+
local key="$1" default="$2"
|
|
68
|
+
local local_v global_v
|
|
69
|
+
local_v=$(jq -r ".confluence.rollup.${key} // empty" .lisa.config.local.json 2>/dev/null)
|
|
70
|
+
global_v=$(jq -r ".confluence.rollup.${key} // empty" .lisa.config.json 2>/dev/null)
|
|
71
|
+
echo "${local_v:-${global_v:-$default}}"
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
CLOSE_ON_SHIPPED=$(read_rollup_flag closeOnShipped false)
|
|
62
75
|
```
|
|
63
76
|
|
|
64
77
|
In prose below, the role names refer to the resolved parent-page IDs: e.g. "the `ready` parent" means whatever `confluence.parents.ready` resolves to.
|
|
65
78
|
|
|
66
|
-
This skill is the Confluence counterpart of `lisa:notion-prd-intake`. The phases, gates, comment templates, and rules are identical — the only differences are (1) the lifecycle is encoded as **parent-page placement** instead of a status property, and (2) the fetch / comment / update tools route through `lisa:atlassian-access`. Keep
|
|
79
|
+
This skill is the Confluence counterpart of `lisa:notion-prd-intake`, and shares its PRD closure rollup phase (3f) with `lisa:github-prd-intake` and `lisa:linear-prd-intake`. The phases, gates, comment templates, and rules are identical — the only differences are (1) the lifecycle is encoded as **parent-page placement** instead of a status property, and (2) the fetch / comment / update tools route through `lisa:atlassian-access`. Keep all four intake skills behaviorally aligned: when changing intake logic — including the rollup phase — change them together.
|
|
80
|
+
|
|
81
|
+
The **PRD closure rollup phase (3f)** re-parents a `ticketed` PRD to the `shipped` parent (and optionally archives it) once all its generated top-level work is terminal, per the `prd-lifecycle-rollup` rule. This is the Confluence leg of the same vendor-neutral rollup that `lisa:github-prd-intake` implements for GitHub (LPC-1.3 #584); only the vendor surface (parent-page placement + documented generated-work section, since Confluence has no native ticket hierarchy) differs.
|
|
67
82
|
|
|
68
83
|
## Confirmation policy
|
|
69
84
|
|
|
@@ -93,13 +108,15 @@ draft → ready → in_review → blocked | ticketed → shipped
|
|
|
93
108
|
|
|
94
109
|
A PRD's current state is determined entirely by which lifecycle parent it sits under. Re-parenting is the transition.
|
|
95
110
|
|
|
96
|
-
This skill
|
|
111
|
+
This skill transitions:
|
|
97
112
|
|
|
98
113
|
- `ready` → `in_review` (claim)
|
|
99
114
|
- `in_review` → `blocked` (gate failures or coverage gaps)
|
|
100
115
|
- `in_review` → `ticketed` (success)
|
|
116
|
+
- `ticketed` → `blocked` (post-write coverage gaps from Phase 3e)
|
|
117
|
+
- `ticketed` → `shipped` (PRD closure rollup, Phase 3f — only when **all** generated top-level children are terminal)
|
|
101
118
|
|
|
102
|
-
It never re-parents PRDs into or out of the `draft`
|
|
119
|
+
It never re-parents PRDs into or out of the `draft` parent — that parent is owned by product. The `shipped` parent is set by this skill's **rollup phase (3f)** when, and only when, the PRD's generated top-level work is all terminal — per the `prd-lifecycle-rollup` rule; product may also re-parent there by hand. Rollup never advances a PRD to `shipped` on partial completion, and never archives a PRD page unless `confluence.rollup.closeOnShipped` is configured `true` (default `false` → re-parent under `shipped`, leave the page active).
|
|
103
120
|
|
|
104
121
|
A "transition" means: update the PRD's `parentId` to the new role's parent-page id via `lisa:atlassian-access` `operation: write-page payload: { id, parentId, title, version: { number: <next> } }`. The v2 PUT endpoint requires the next version number and the page title in the payload; the body content is not strictly required for a re-parent-only edit, but some Atlassian deployments reject PUTs without a body. The skill MUST therefore GET the page first via `read-page`, capture title + current version + current body, then PUT with `parentId` swapped and `version.number` bumped — preserving body content is non-negotiable, this skill never edits PRD content. See `transition_prd` helper in Phase 3a for the canonical implementation.
|
|
105
122
|
|
|
@@ -276,6 +293,61 @@ Per-ticket gates prove each ticket is well-formed; they do NOT prove the *set* o
|
|
|
276
293
|
|
|
277
294
|
3. The created tickets remain in the destination tracker regardless of the verdict — they are valid in their own right. The audit only tells us whether *more* are needed.
|
|
278
295
|
|
|
296
|
+
#### 3f. PRD closure rollup (config-gated)
|
|
297
|
+
|
|
298
|
+
A PRD's lifecycle terminal state (`shipped`) is **derived** from whether the work it generated is done — it is never set by hand here on its own authority. This phase implements the Confluence leg of that derivation, per the `prd-lifecycle-rollup` rule (cite it by slug; do not restate its taxonomy or terminal-state semantics here). It is behaviorally identical to `lisa:github-prd-intake`'s Phase 3f — only the vendor surface (parent-page re-parenting via `lisa:atlassian-access` + the documented generated-work section) differs from GitHub's (issue close + labels via `gh`).
|
|
299
|
+
|
|
300
|
+
Rollup runs over PRD pages that are already under the `ticketed` parent (the only state from which a PRD can ship): the freshly-ticketed PRD from Phase 3c, and — because rollup also catches PRDs whose children finished in a *later* cycle — every page currently parented under `$TICKETED_PARENT`. (Re-read its direct children via `lisa:atlassian-access` `operation: read-page-descendants id: $TICKETED_PARENT`.) Process each independently; one PRD never blocks another's rollup.
|
|
301
|
+
|
|
302
|
+
##### 3f.0 Resolve closure config
|
|
303
|
+
|
|
304
|
+
Closure is gated on `confluence.rollup.closeOnShipped` (default `false`), resolved via `read_rollup_flag` (defined in the Workflow resolution block, same local-overrides-global precedence the lifecycle parents use). Note the config lives under `confluence.rollup` (NOT `confluence.parents.rollup`):
|
|
305
|
+
|
|
306
|
+
```bash
|
|
307
|
+
CLOSE_ON_SHIPPED=$(read_rollup_flag closeOnShipped false)
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
When `false` (the default), rollup re-parents the PRD under `$SHIPPED_PARENT` but leaves the page **active** for a human to archive. When `true`, rollup also archives the page (where the deployment supports archival) after the `shipped` re-parent. Closure NEVER happens before all generated top-level work is terminal (`prd-lifecycle-rollup` rule; PRD #525 non-goal).
|
|
311
|
+
|
|
312
|
+
##### 3f.1 Idempotency guard (no-op if already shipped)
|
|
313
|
+
|
|
314
|
+
Rollup is keyed by the PRD's current state. If the PRD is already parented under `$SHIPPED_PARENT` (and is already archived, when `$CLOSE_ON_SHIPPED` is `true`), it is a **no-op** — do not re-parent, do not re-archive, do not re-comment. Record it as `already shipped (no-op)` in the cycle summary and move on. This is what makes re-running intake safe.
|
|
315
|
+
|
|
316
|
+
##### 3f.2 Read the generated top-level child set
|
|
317
|
+
|
|
318
|
+
Read the PRD's **generated top-level work** — its created Epics and any top-level Stories created directly under it, **excluding** leaf Sub-tasks and any Story nested under a generated Epic (`prd-lifecycle-rollup` rule, generated-top-level-work contract). Confluence has **no native ticket hierarchy**, so the child set comes from the documented section only:
|
|
319
|
+
|
|
320
|
+
1. **Documented `## Tickets` section (primary and only source).** Parse the machine-readable generated-work section `lisa:prd-backlink` writes to the PRD body (`## Tickets`, alias `## Generated Work`; see #582) via `lisa:atlassian-access` `operation: read-page id: <PRD-ID>`. Top-level children are the `### <Epic key>: <title>` group headers' first line (`- [<ref>](<url>) — Epic`) plus any top-level Story listed directly under `### Unparented items`. Lines nested deeper (` - ... — Story:` under an Epic, ` - ... — Sub-task:`) are descendants, NOT top-level children — skip them.
|
|
321
|
+
|
|
322
|
+
Dedupe the resulting child set by **child-ref identity** — the destination ticket ref recorded in each generated-work entry (the entry is keyed by that ref, not by list position) — per the `prd-lifecycle-rollup` idempotency dedupe key. If the section yields no child (the PRD generated nothing, or the relationship was never recorded), record `no generated top-level children — rollup skipped` and leave the PRD under `$TICKETED_PARENT`; do not ship an empty PRD.
|
|
323
|
+
|
|
324
|
+
##### 3f.3 Apply the terminal-state predicate
|
|
325
|
+
|
|
326
|
+
For each top-level child, classify per the `prd-lifecycle-rollup` Confluence/Notion predicate:
|
|
327
|
+
|
|
328
|
+
- **Terminal (shipped).** The documented generated-work entry for the child is marked **done** in the PRD's machine-readable section (the durable equivalent of a closed ticket, since Confluence has no native ticket state). A child Epic is terminal only when it has itself rolled up to its own terminal state per `leaf-only-lifecycle` — read the child's own recorded state; do not re-derive it from its leaves here.
|
|
329
|
+
- **Terminal-but-dropped.** The entry is marked won't-do / canceled. Like a not-planned leaf, it does not hold the PRD open and is excluded from the shipped set.
|
|
330
|
+
- **Incomplete / blocked.** Anything else: the entry is not yet marked done. Holds the PRD open.
|
|
331
|
+
|
|
332
|
+
The set of **required** children for the all-terminal check is the top-level children minus the terminal-but-dropped ones.
|
|
333
|
+
|
|
334
|
+
##### 3f.4 Branch on the rollup verdict
|
|
335
|
+
|
|
336
|
+
**All required children terminal** (every required top-level child is terminal; at least one required child exists):
|
|
337
|
+
|
|
338
|
+
1. Re-parent to `shipped`: `transition_prd "$PRD_ID" shipped` (GET-then-PUT via `lisa:atlassian-access` preserving the body verbatim). After the re-parent, re-read the page and confirm `parentId` matches `$SHIPPED_PARENT` (the single-parent invariant).
|
|
339
|
+
2. **If `$CLOSE_ON_SHIPPED` is `true`**, archive the PRD page where the deployment supports archival. When `false`, leave it active.
|
|
340
|
+
3. Post a short rollup footer comment via `lisa:atlassian-access` `operation: comment-page kind: footer` naming the terminal child set and (when dropped children exist) the dropped set, so the audit trail records *why* the PRD shipped. Lead with `"Shipped by Claude — all generated top-level work is complete."`
|
|
341
|
+
|
|
342
|
+
**Any required child incomplete / blocked**:
|
|
343
|
+
|
|
344
|
+
1. Leave the PRD under `$TICKETED_PARENT` and leave the page **active**. Do NOT re-parent to `shipped`. Do NOT archive.
|
|
345
|
+
2. Report the incomplete child set — both in the cycle summary and, when at least one cycle has previously ticketed this PRD, as a single advisory footer comment listing the still-open children (`- <ref> "<title>" — <state>`), so product can see what's blocking the rollup. Keep it idempotent: regenerate the advisory rather than appending a fresh one each cycle.
|
|
346
|
+
|
|
347
|
+
##### 3f.5 Rollup cites the rule
|
|
348
|
+
|
|
349
|
+
This phase implements exactly one PRD-lifecycle hop — `ticketed → shipped` — and the optional config-gated archive that follows it. All terminal-state semantics, the generated-top-level-work boundary, and the dedupe-by-child-ref idempotency come from the `prd-lifecycle-rollup` rule; this skill is its Confluence implementation, not a second source of truth.
|
|
350
|
+
|
|
279
351
|
### Phase 4 — Summary report
|
|
280
352
|
|
|
281
353
|
After processing every ready PRD, emit a summary:
|
|
@@ -304,10 +376,11 @@ Print to the agent's output. Do not write this summary to Confluence or the dest
|
|
|
304
376
|
## Idempotency & safety
|
|
305
377
|
|
|
306
378
|
- **Single-cycle scope**: this skill processes the ready set as it exists at the start of Phase 2. New PRDs moved under the `ready` parent mid-cycle are picked up next run.
|
|
307
|
-
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:confluence-to-tracker` (which delegates to `lisa:tracker-write`), and only ever re-parents PRDs among `in_review`, `blocked`, and `
|
|
379
|
+
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:confluence-to-tracker` (which delegates to `lisa:tracker-write`), and only ever re-parents PRDs among `in_review`, `blocked`, `ticketed`, and `shipped` (the last via the rollup phase 3f only) via `lisa:atlassian-access` `operation: write-page`. It never edits PRD body content, never re-parents into or out of `draft`, never deletes pages. It re-parents under `shipped` and may archive the PRD page **only** through the config-gated rollup phase (3f).
|
|
308
380
|
- **Claim-first ordering**: the re-parent to `in_review` happens BEFORE validation runs, so a re-entrant call won't double-process.
|
|
309
381
|
- **Failure isolation**: an exception processing one PRD must not stop the cycle. Catch, record under "Errors" in the summary, continue to the next PRD. The PRD that errored is left under whatever parent it currently occupies (usually `in_review` if claim succeeded) — the human investigates from there.
|
|
310
382
|
- **Single-parent invariant**: a page has exactly one parent by construction in Confluence — the multi-state ambiguity that label-based systems can hit (two `prd-*` labels simultaneously) cannot occur here. After every transition, re-read the page and confirm `parentId` matches the expected role; if not, surface as an Error and skip.
|
|
383
|
+
- **Rollup idempotency**: rollup (Phase 3f) is a no-op on a PRD already parented under `$SHIPPED_PARENT` (and already archived when `closeOnShipped` is `true`) — no duplicate re-parent, no duplicate archive, no duplicate comment. The all-terminal condition is a pure function of the children's current states (deduped by child-ref identity), so recomputing it is safe to re-run. Archival NEVER precedes the all-terminal condition.
|
|
311
384
|
|
|
312
385
|
## Configuration
|
|
313
386
|
|
|
@@ -325,12 +398,14 @@ Destination tracker config (jira / github / linear) is consumed by `lisa:tracker
|
|
|
325
398
|
| `.lisa.config.json` `confluence.parents.blocked` | yes | Parent page id for "validation failure" |
|
|
326
399
|
| `.lisa.config.json` `confluence.parents.ticketed` | yes | Parent page id for "successfully ticketed" |
|
|
327
400
|
| `.lisa.config.json` `confluence.parents.draft` | recommended | Parent page id for PRDs still being drafted by product |
|
|
328
|
-
| `.lisa.config.json` `confluence.parents.shipped` | recommended | Parent page id
|
|
401
|
+
| `.lisa.config.json` `confluence.parents.shipped` | recommended | Parent page id the rollup phase (3f) re-parents delivered PRDs under; product may also use it by hand |
|
|
402
|
+
| `.lisa.config.json` `confluence.rollup.closeOnShipped` | no (default `false`) | When `true`, rollup archives the PRD page after the `shipped` re-parent; when `false`, re-parents under `shipped` and leaves the page active |
|
|
329
403
|
|
|
330
404
|
## Rules
|
|
331
405
|
|
|
332
406
|
- Never write to the destination tracker outside of `lisa:confluence-to-tracker` → `lisa:tracker-write`. The validator's verdict gates progress; bypassing it produces broken tickets.
|
|
333
|
-
- Never re-parent a PRD into a lifecycle parent this skill doesn't own (`in_review`, `blocked`, `ticketed`). Product owns `draft
|
|
407
|
+
- Never re-parent a PRD into a lifecycle parent this skill doesn't own (`in_review`, `blocked`, `ticketed`, and `shipped` via the rollup phase only). Product owns `draft` and `ready` (as the entry signal); product and the rollup phase (3f) both re-parent under `shipped`.
|
|
408
|
+
- Re-parent under `shipped` (and archive the PRD page when `closeOnShipped` is configured) only from the rollup phase, and only when all generated top-level children are terminal per the `prd-lifecycle-rollup` rule. Never ship or archive on partial completion.
|
|
334
409
|
- Never edit the PRD's body. Communication with product happens only through Confluence comments. The `write-page` call preserves the body verbatim — fetch then PUT with body unchanged.
|
|
335
410
|
- Never post a single page-level dump of all gate failures. One inline comment per `prd_anchor` group (or one footer summary for unanchored failures only). Comments must be inline-anchored where possible, categorized, plain-language, and contain a concrete recommendation.
|
|
336
411
|
- Never include a gate ID, internal skill name, or engineering shorthand in a comment body.
|
|
@@ -39,6 +39,8 @@ In prose below, the role names refer to the resolved labels: e.g. "the `ready` l
|
|
|
39
39
|
|
|
40
40
|
This skill is the GitHub counterpart of `lisa:notion-prd-intake`, `lisa:confluence-prd-intake`, and `lisa:linear-prd-intake`. Phases, gates, comment templates, and rules are identical — the only differences are (1) the lifecycle is encoded as **issue labels** (mirroring Linear's project labels and Confluence's page labels), (2) the fetch / update tools are the `gh` CLI, and (3) clarifying-question comments land directly on the source PRD issue (because GitHub Issues *do* have native comments — no sentinel issue required, unlike Linear). Keep all four skills behaviorally aligned: when changing intake logic, change them together.
|
|
41
41
|
|
|
42
|
+
The **PRD closure rollup phase (3f)** transitions a `$TICKETED` PRD to `$SHIPPED` (and optionally closes it) once all its generated top-level work is terminal, per the `prd-lifecycle-rollup` rule. This phase is GitHub-only here because its vendor surface (issue close + labels via `gh`) is GitHub-specific; the Linear / Confluence / Notion intake skills carry the **same** vendor-neutral rollup with their own surfaces (sibling sub-task #584, now landed). All four intake skills are behaviorally aligned across the rollup phase too — keep them in sync when changing rollup logic.
|
|
43
|
+
|
|
42
44
|
## Confirmation policy
|
|
43
45
|
|
|
44
46
|
Do NOT ask the caller whether to proceed. Once invoked with a repo, run the cycle to completion — claim, validate, branch to `$BLOCKED` or `$TICKETED`, write the summary. The caller has already authorized the run by invoking the skill; re-prompting defeats the purpose of a background batch.
|
|
@@ -69,14 +71,15 @@ draft → ready → in_review → blocked | ticketed → shipped
|
|
|
69
71
|
|
|
70
72
|
Exactly one of these labels is expected on a PRD issue at any time.
|
|
71
73
|
|
|
72
|
-
This skill
|
|
74
|
+
This skill transitions:
|
|
73
75
|
|
|
74
76
|
- `$READY` → `$IN_REVIEW` (claim)
|
|
75
77
|
- `$IN_REVIEW` → `$BLOCKED` (gate failures or coverage gaps)
|
|
76
78
|
- `$IN_REVIEW` → `$TICKETED` (success)
|
|
77
79
|
- `$TICKETED` → `$BLOCKED` (post-write coverage gaps from Phase 3e)
|
|
80
|
+
- `$TICKETED` → `$SHIPPED` (PRD closure rollup, Phase 3f — only when **all** generated top-level children are terminal)
|
|
78
81
|
|
|
79
|
-
|
|
82
|
+
The `draft` label is owned by product and is never touched here. The `shipped` label is set by this skill's **rollup phase (3f)** when, and only when, the PRD's generated top-level work is all terminal — per the `prd-lifecycle-rollup` rule; product may also set it by hand. Rollup never advances a PRD to `shipped` on partial completion, and never closes a PRD issue unless `github.labels.prd.rollup.closeOnShipped` is configured `true` (default `false` → set `shipped`, leave open).
|
|
80
83
|
|
|
81
84
|
A "transition" means: remove the old lifecycle label and add the new one (`gh issue edit <num> --remove-label <old> --add-label <new>`). The skill MUST verify exactly one lifecycle label is present after the update.
|
|
82
85
|
|
|
@@ -240,6 +243,99 @@ Per-ticket gates prove each ticket is well-formed; they do NOT prove the *set* o
|
|
|
240
243
|
|
|
241
244
|
3. The created tickets remain in the destination tracker regardless of the verdict. The audit only tells us whether *more* are needed.
|
|
242
245
|
|
|
246
|
+
#### 3f. PRD closure rollup (config-gated)
|
|
247
|
+
|
|
248
|
+
A PRD's lifecycle terminal state (`shipped`) is **derived** from whether the work it generated is done — it is never set by hand here on its own authority. This phase implements the GitHub leg of that derivation, per the `prd-lifecycle-rollup` rule (cite it by slug; do not restate its taxonomy or terminal-state semantics here). Linear / Confluence / Notion rollup is a sibling sub-task (#584) and is out of scope for this skill.
|
|
249
|
+
|
|
250
|
+
Rollup runs over PRD issues that are already `$TICKETED` (the only state from which a PRD can ship): the freshly-ticketed PRD from Phase 3c, and — because rollup also catches PRDs whose children finished in a *later* cycle — every issue currently carrying `$TICKETED`. Process each independently; one PRD never blocks another's rollup.
|
|
251
|
+
|
|
252
|
+
##### 3f.0 Resolve closure config
|
|
253
|
+
|
|
254
|
+
Closure is gated on `github.labels.prd.rollup.closeOnShipped` (default `false`). Resolve it with the same local-overrides-global precedence the lifecycle labels use:
|
|
255
|
+
|
|
256
|
+
```bash
|
|
257
|
+
# Resolve a boolean rollup flag. Local overrides global per-key; default when unset.
|
|
258
|
+
read_rollup_flag() {
|
|
259
|
+
local key="$1" default="$2"
|
|
260
|
+
local local_v global_v
|
|
261
|
+
local_v=$(jq -r ".github.labels.prd.rollup.${key} // empty" .lisa.config.local.json 2>/dev/null)
|
|
262
|
+
global_v=$(jq -r ".github.labels.prd.rollup.${key} // empty" .lisa.config.json 2>/dev/null)
|
|
263
|
+
echo "${local_v:-${global_v:-$default}}"
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
CLOSE_ON_SHIPPED=$(read_rollup_flag closeOnShipped false)
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
When `false` (the default), rollup sets `$SHIPPED` but leaves the PRD issue **open** for a human to close. When `true`, rollup also closes the PRD issue after the `$SHIPPED` transition. Closure NEVER happens before all generated top-level work is terminal (`prd-lifecycle-rollup` rule; PRD #525 non-goal).
|
|
270
|
+
|
|
271
|
+
##### 3f.1 Idempotency guard (no-op if already shipped)
|
|
272
|
+
|
|
273
|
+
Rollup is keyed by the PRD's current state. If the PRD already carries `$SHIPPED` (and is already closed, when `$CLOSE_ON_SHIPPED` is `true`), it is a **no-op** — do not re-transition, do not re-close, do not re-comment. Record it as `already shipped (no-op)` in the cycle summary and move on. This is what makes re-running intake safe.
|
|
274
|
+
|
|
275
|
+
##### 3f.2 Read the generated top-level child set
|
|
276
|
+
|
|
277
|
+
Read the PRD's **generated top-level work** — its created Epics and any top-level Stories created directly under it, **excluding** leaf Sub-tasks and any Story nested under a generated Epic (`prd-lifecycle-rollup` rule, generated-top-level-work contract). Use two sources, native first:
|
|
278
|
+
|
|
279
|
+
1. **Native sub-issues (primary).** Traverse the PRD issue's native sub-issue graph via the GraphQL `subIssues` query (the same query `lisa:github-read-issue` Phase 3 uses). The PRD's direct `subIssues` nodes are its top-level children:
|
|
280
|
+
|
|
281
|
+
```bash
|
|
282
|
+
gh api graphql -f query='
|
|
283
|
+
query($org:String!,$repo:String!,$number:Int!){
|
|
284
|
+
repository(owner:$org,name:$repo){
|
|
285
|
+
issue(number:$number){
|
|
286
|
+
subIssues(first: 100) {
|
|
287
|
+
nodes {
|
|
288
|
+
number title state url
|
|
289
|
+
repository { nameWithOwner }
|
|
290
|
+
labels(first: 50) { nodes { name } }
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
}' -F org=<org> -F repo=<repo> -F number=<prd-num>
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
2. **Documented `## Tickets` section (fallback).** When native sub-issues are unavailable (older GHES, sub-issues feature off, or the source PRD and the destination tracker are different systems so the children were never linked as sub-issues), parse the machine-readable generated-work section `lisa:prd-backlink` writes to the PRD body (`## Tickets`, alias `## Generated Work`; see #582). Top-level children are the `### <Epic key>: <title>` group headers' first line (`- [<ref>](<url>) — Epic`) plus any top-level Story listed directly under `### Unparented items`. Lines nested deeper (` - ... — Story:` under an Epic, ` - ... — Sub-task:`) are descendants, NOT top-level children — skip them.
|
|
299
|
+
|
|
300
|
+
```bash
|
|
301
|
+
# Top-level child refs = Epic lines (top indent) + Unparented top-level Stories.
|
|
302
|
+
# Sub-tasks and Stories nested under an Epic are descendants — excluded.
|
|
303
|
+
gh issue view <prd-num> --repo <org>/<repo> --json body --jq '.body' \
|
|
304
|
+
| awk '/^## (Tickets|Generated Work)/{insec=1;next} /^## /{insec=0}
|
|
305
|
+
insec && /^- \[.*\] — Epic/{print}
|
|
306
|
+
insec && /^### Unparented items/{unp=1;next}
|
|
307
|
+
insec && unp && /^- \[.*\] — Story/{print}'
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
Dedupe the resulting child set by **child-ref identity** (`owner/repo#number`) so a child that appears both as a native sub-issue and in the documented section is counted once (`prd-lifecycle-rollup` idempotency dedupe key). If neither source yields any child (the PRD generated nothing, or the relationship was never recorded), record `no generated top-level children — rollup skipped` and leave the PRD as `$TICKETED`; do not ship an empty PRD.
|
|
311
|
+
|
|
312
|
+
##### 3f.3 Apply the terminal-state predicate
|
|
313
|
+
|
|
314
|
+
For each top-level child, fetch its state + labels (already present from the GraphQL nodes, or `gh issue view <child-num> --json state,labels`) and classify per the `prd-lifecycle-rollup` GitHub predicate:
|
|
315
|
+
|
|
316
|
+
- **Terminal (shipped).** The child issue is **CLOSED** *and* (where the build-status label is in use) carries the resolved build `done` role label (`status:done` by default). A child Epic is terminal only when it has itself rolled up to its own terminal state per `leaf-only-lifecycle` — read the child's own resolved state; do not re-derive it from its leaves here.
|
|
317
|
+
- **Terminal-but-dropped.** The child is closed **as not planned** (`stateReason == "not_planned"`). It does not hold the PRD open and is excluded from the shipped set — treated like a won't-do leaf.
|
|
318
|
+
- **Incomplete / blocked.** Anything else: still open, or closed without the `done` label. Holds the PRD open.
|
|
319
|
+
|
|
320
|
+
The set of **required** children for the all-terminal check is the top-level children minus the terminal-but-dropped ones.
|
|
321
|
+
|
|
322
|
+
##### 3f.4 Branch on the rollup verdict
|
|
323
|
+
|
|
324
|
+
**All required children terminal** (every required top-level child is terminal; at least one required child exists):
|
|
325
|
+
|
|
326
|
+
1. Transition labels: `gh issue edit <prd-num> --repo <org>/<repo> --remove-label "$TICKETED" --add-label "$SHIPPED"`. Verify exactly one lifecycle label remains (the single-label invariant).
|
|
327
|
+
2. **If `$CLOSE_ON_SHIPPED` is `true`**, close the PRD issue: `gh issue close <prd-num> --repo <org>/<repo> --reason completed`. When `false`, leave it open.
|
|
328
|
+
3. Post a short rollup comment naming the terminal child set and (when dropped children exist) the dropped set, so the audit trail records *why* the PRD shipped. Lead with `"Shipped by Claude — all generated top-level work is complete."`
|
|
329
|
+
|
|
330
|
+
**Any required child incomplete / blocked**:
|
|
331
|
+
|
|
332
|
+
1. Leave the PRD label as `$TICKETED` and leave the issue **open**. Do NOT add `$SHIPPED`. Do NOT close.
|
|
333
|
+
2. Report the incomplete child set — both in the cycle summary and, when at least one cycle has previously ticketed this PRD, as a single advisory comment listing the still-open children (`- <ref> "<title>" — <state>`), so product can see what's blocking the rollup. Keep it idempotent: regenerate the advisory rather than appending a fresh one each cycle.
|
|
334
|
+
|
|
335
|
+
##### 3f.5 Rollup is GitHub-only and cites the rule
|
|
336
|
+
|
|
337
|
+
This phase only touches GitHub PRD issues. It implements exactly one PRD-lifecycle hop — `$TICKETED → $SHIPPED` — and the optional config-gated close that follows it. All terminal-state semantics, the generated-top-level-work boundary, the env-keyed `done` resolution, and the dedupe-by-child-ref idempotency come from the `prd-lifecycle-rollup` rule; this skill is its GitHub implementation, not a second source of truth.
|
|
338
|
+
|
|
243
339
|
### Phase 4 — Summary report
|
|
244
340
|
|
|
245
341
|
```text
|
|
@@ -257,6 +353,14 @@ PRDs processed: <n>
|
|
|
257
353
|
- Errors (claim failed, etc): <n>
|
|
258
354
|
- <issue-ref> "<title>" — <reason>
|
|
259
355
|
|
|
356
|
+
Rollup (Phase 3f):
|
|
357
|
+
- $SHIPPED: <n>
|
|
358
|
+
- <issue-ref> "<title>" → all <child-count> top-level children terminal (<dropped-count> dropped); closed: <yes|no (closeOnShipped off)>
|
|
359
|
+
- Held open (incomplete children): <n>
|
|
360
|
+
- <issue-ref> "<title>" → <incomplete-count> of <child-count> top-level children still open
|
|
361
|
+
- Already shipped (no-op): <n>
|
|
362
|
+
- No generated children (rollup skipped): <n>
|
|
363
|
+
|
|
260
364
|
Total tickets created: <n>
|
|
261
365
|
Coverage audit summary: <n> COMPLETE / <n> COMPLETE_WITH_SCOPE_CREEP / <n> GAPS_FOUND
|
|
262
366
|
```
|
|
@@ -274,10 +378,11 @@ When the configured destination tracker is GitHub Issues AND the PRD repo is the
|
|
|
274
378
|
## Idempotency & safety
|
|
275
379
|
|
|
276
380
|
- **Single-cycle scope**: this skill processes the ready set as it exists at the start of Phase 2. New ready issues added mid-cycle are picked up next run.
|
|
277
|
-
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:github-to-tracker` (which delegates to `lisa:tracker-write`), only ever changes labels among `$IN_REVIEW`, `$BLOCKED`, `$TICKETED`, only ever comments on the source PRD issue. It never edits PRD bodies
|
|
381
|
+
- **No writes outside the lifecycle**: this skill only ever writes to the destination tracker via `lisa:github-to-tracker` (which delegates to `lisa:tracker-write`), only ever changes labels among `$IN_REVIEW`, `$BLOCKED`, `$TICKETED`, `$SHIPPED`, only ever comments on the source PRD issue. It never edits PRD bodies and never touches the `draft` label. It sets the `$SHIPPED` label and may close the PRD issue **only** through the config-gated rollup phase (3f), and never deletes any issue.
|
|
278
382
|
- **Claim-first ordering**: the label flip to `$IN_REVIEW` happens BEFORE validation runs.
|
|
279
383
|
- **Failure isolation**: an exception processing one PRD must not stop the cycle. Catch, record under "Errors" in the summary, continue. The PRD that errored is left labeled `$IN_REVIEW` — humans investigate from there.
|
|
280
384
|
- **Single-label invariant**: after every transition, verify exactly one lifecycle label is present.
|
|
385
|
+
- **Rollup idempotency**: rollup (Phase 3f) is a no-op on a PRD already carrying `$SHIPPED` (and already closed when `closeOnShipped` is `true`) — no duplicate transition, no duplicate close, no duplicate comment. The all-terminal condition is a pure function of the children's current states, so recomputing it is safe to re-run. Closure NEVER precedes the all-terminal condition.
|
|
281
386
|
|
|
282
387
|
## Configuration
|
|
283
388
|
|
|
@@ -299,7 +404,8 @@ Destination tracker config (jira / github / linear) is consumed by `lisa:tracker
|
|
|
299
404
|
## Rules
|
|
300
405
|
|
|
301
406
|
- Never write to the destination tracker outside of `lisa:github-to-tracker` → `lisa:tracker-write`.
|
|
302
|
-
- Never add or remove a label this skill doesn't own (`$IN_REVIEW`, `$BLOCKED`, `$TICKETED`). Product owns the `draft
|
|
407
|
+
- Never add or remove a label this skill doesn't own (`$IN_REVIEW`, `$BLOCKED`, `$TICKETED`, and `$SHIPPED` via the rollup phase only). Product owns the `draft` and `ready` PRD labels; product and the rollup phase (3f) both set `shipped`.
|
|
408
|
+
- Set `$SHIPPED` (and close the PRD when `closeOnShipped` is configured) only from the rollup phase, and only when all generated top-level children are terminal per the `prd-lifecycle-rollup` rule. Never ship or close on partial completion.
|
|
303
409
|
- Never edit a PRD's body. Communication with product happens only via comments.
|
|
304
410
|
- Never post a single dump of all gate failures on one comment. One comment per `prd_anchor` group, plus one rollup for unanchored failures.
|
|
305
411
|
- Never include a gate ID, internal skill name, or engineering shorthand in a comment body.
|