@danmoisan/drm-copilot-mcp 1.0.15 → 1.0.17
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/resources/claude-customizations/.claude/agents/epic-orchestrator.md +13 -4
- package/resources/claude-customizations/.claude/hooks/validate-planner-output.ps1 +5 -5
- package/resources/claude-customizations/.claude/skills/epic-run/SKILL.md +22 -4
- package/resources/codex-and-agents-customizations/.codex/config.toml +1 -1
- package/resources/powershell/PoshQC/settings/pester.runsettings.psd1 +3 -0
package/package.json
CHANGED
|
@@ -77,10 +77,19 @@ chain; the PreToolUse hook `.claude/hooks/enforce-epic-invocation-origin.ps1` de
|
|
|
77
77
|
|
|
78
78
|
## Prepared-Epic Execution (epic-planner Handoff)
|
|
79
79
|
|
|
80
|
-
When the epic was prepared by `epic-planner
|
|
81
|
-
`
|
|
82
|
-
|
|
83
|
-
|
|
80
|
+
When the epic was prepared by `epic-planner`, the integration branch
|
|
81
|
+
`epic/<epic-slug>-integration` already exists and carries the committed kickoff artifact and
|
|
82
|
+
every prepared child feature folder. Because `epic-plan` commits those outputs to the integration
|
|
83
|
+
branch (worked in a separate integration worktree), do not assume they are present in the invoking
|
|
84
|
+
worktree: establish their presence by fetching and reading from the integration branch rather than
|
|
85
|
+
gating on a local checkout. Run `git fetch origin epic/<epic-slug>-integration`, then read
|
|
86
|
+
`docs/features/epics/<epic-slug>/epic-kickoff.md` from that ref — for example
|
|
87
|
+
`git show origin/epic/<epic-slug>-integration:docs/features/epics/<epic-slug>/epic-kickoff.md`, or
|
|
88
|
+
test existence with
|
|
89
|
+
`git cat-file -e epic/<epic-slug>-integration:docs/features/epics/<epic-slug>/epic-kickoff.md` —
|
|
90
|
+
without checking the integration branch out into the invoking worktree. Once the integration branch
|
|
91
|
+
is fetched, each child feature folder on it already contains its issue, research, `spec.md`,
|
|
92
|
+
`user-story.md`, an approved atomic plan, and a recorded preflight clearance. In that case:
|
|
84
93
|
|
|
85
94
|
1. Do not recreate the integration branch; fetch and reuse it.
|
|
86
95
|
2. Each child `Agent(orchestrator)` delegation prompt cites the child's committed `plan-path`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<#
|
|
1
|
+
<#
|
|
2
2
|
.SYNOPSIS
|
|
3
3
|
SubagentStop hook for the atomic-planner subagent.
|
|
4
4
|
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
- output contains `PREFLIGHT: ALL CLEAR` or
|
|
15
15
|
`PREFLIGHT: REVISIONS REQUIRED`,
|
|
16
16
|
- the advertised plan exists on disk,
|
|
17
|
-
- the plan contains canonical `### Phase N
|
|
17
|
+
- the plan contains canonical `### Phase N — <Title>` headings,
|
|
18
18
|
- Phase 0 exists and includes policy-read and baseline tasks,
|
|
19
19
|
- each task uses `- [ ] [P#-T#]` (or checked equivalent),
|
|
20
20
|
- task numbering is sequential within each phase,
|
|
@@ -118,7 +118,7 @@ function Get-PlanStructureValidationReport {
|
|
|
118
118
|
[string[]] $Lines
|
|
119
119
|
)
|
|
120
120
|
|
|
121
|
-
$phasePattern = '^### Phase (?<Phase>\d+)\s
|
|
121
|
+
$phasePattern = '^### Phase (?<Phase>\d+)\s+—\s+(?<Title>.+)$'
|
|
122
122
|
$taskPattern = '^- \[(?<State>[ xX])\] \[P(?<Phase>\d+)-T(?<Task>\d+)\] (?<Text>.+)$'
|
|
123
123
|
$errors = [System.Collections.Generic.List[string]]::new()
|
|
124
124
|
$tasksByPhase = @{}
|
|
@@ -134,7 +134,7 @@ function Get-PlanStructureValidationReport {
|
|
|
134
134
|
if ($line -match '^### Phase ') {
|
|
135
135
|
$phaseMatch = [regex]::Match($line, $phasePattern)
|
|
136
136
|
if (-not $phaseMatch.Success) {
|
|
137
|
-
$errors.Add("Line ${lineNumber}: phase heading must match `### Phase N
|
|
137
|
+
$errors.Add("Line ${lineNumber}: phase heading must match `### Phase N — <Title>`.")
|
|
138
138
|
$currentPhase = $null
|
|
139
139
|
continue
|
|
140
140
|
}
|
|
@@ -245,7 +245,7 @@ function Invoke-PlannerOutputValidation {
|
|
|
245
245
|
}
|
|
246
246
|
|
|
247
247
|
$agentOutput = $null
|
|
248
|
-
if ($payload.PSObject.Properties
|
|
248
|
+
if ($null -ne $payload.PSObject.Properties['output']) {
|
|
249
249
|
$agentOutput = $payload.output
|
|
250
250
|
}
|
|
251
251
|
if ([string]::IsNullOrWhiteSpace($agentOutput)) {
|
|
@@ -18,10 +18,28 @@ $ARGUMENTS
|
|
|
18
18
|
|
|
19
19
|
1. Resolve the epic home. A bare slug resolves to `docs/features/epics/<epic-slug>/`; a path
|
|
20
20
|
argument resolves to its containing epic folder.
|
|
21
|
-
2.
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
2. Resolve the committed kickoff artifact `docs/features/epics/<epic-slug>/epic-kickoff.md`. It
|
|
22
|
+
may exist only on the epic integration branch: `epic-plan` commits it to
|
|
23
|
+
`epic/<epic-slug>-integration` (worked in a separate integration worktree), so the worktree
|
|
24
|
+
that invokes `/epic-run` is not guaranteed to have it checked out. Discover it across both
|
|
25
|
+
locations before concluding it is missing:
|
|
26
|
+
- Attempt `git fetch origin epic/<epic-slug>-integration`. A failure because the remote
|
|
27
|
+
branch does not exist is the genuine "epic not planned" case; tolerate it and continue to
|
|
28
|
+
the local check rather than treating the fetch failure as fatal.
|
|
29
|
+
- Treat the artifact as present when EITHER the plain local path exists in the invoking
|
|
30
|
+
worktree, OR it exists on the fetched integration ref, tested with
|
|
31
|
+
`git cat-file -e epic/<epic-slug>-integration:docs/features/epics/<epic-slug>/epic-kickoff.md`
|
|
32
|
+
(equivalently `origin/epic/<epic-slug>-integration:<path>`).
|
|
33
|
+
- When the artifact is present only on the integration ref, read its content with
|
|
34
|
+
`git show <ref>:<path>`. That is sufficient to extract the `## Invocation Prompt` text
|
|
35
|
+
needed to proceed; do NOT check the integration branch out into the invoking worktree — the
|
|
36
|
+
session worktree must never be checked out onto the integration branch (worktree-isolation
|
|
37
|
+
convention).
|
|
38
|
+
- STOP without delegating anything only when the artifact is absent BOTH locally and on the
|
|
39
|
+
fetched integration branch (the branch does not exist, or exists but lacks the file). In
|
|
40
|
+
that case report that the epic has no committed kickoff artifact: the user must run
|
|
41
|
+
`/epic-plan` first (or, for an epic that was authored manually, invoke
|
|
42
|
+
`/epic-orchestrate <epic-manifest-path>` directly).
|
|
25
43
|
3. Execute the kickoff artifact's `## Invocation Prompt` section as the epic objective, applying
|
|
26
44
|
the `epic-orchestrate` skill procedure and the `## Prepared-Epic Execution (epic-planner
|
|
27
45
|
Handoff)` section of `.claude/agents/epic-orchestrator.md`: reuse the existing integration
|
|
@@ -82,6 +82,9 @@
|
|
|
82
82
|
# to AST-based scriptblocks (Parser::ParseFile(...).GetScriptBlock()) so Pester
|
|
83
83
|
# coverage breakpoints bind to the on-disk source file.
|
|
84
84
|
'scripts/powershell/PoshQC/PoshQC.ScanConfig.psm1'
|
|
85
|
+
# Issue #357 remediation cycle 1 (fix #1): measure the atomic-planner SubagentStop
|
|
86
|
+
# hook so its Pester coverage is captured in the canonical artifact.
|
|
87
|
+
'.claude/hooks/validate-planner-output.ps1'
|
|
85
88
|
)
|
|
86
89
|
# Optional: don't fail the run on coverage percentage
|
|
87
90
|
CoveragePercentTarget = 0
|