Skip to content

chore(agent-memory): record completion-gate receipt shape and collect_pr_context defects (#445 follow-up) - #591

Merged
drmoisan merged 2 commits into
epic/quickfiler-suite-determinism-foundation-integrationfrom
bug/quickfiler-keyboard-action-contract-defects-445-exec
Aug 22, 2026
Merged

chore(agent-memory): record completion-gate receipt shape and collect_pr_context defects (#445 follow-up)#591
drmoisan merged 2 commits into
epic/quickfiler-suite-determinism-foundation-integrationfrom
bug/quickfiler-keyboard-action-contract-defects-445-exec

Conversation

@drmoisan

Copy link
Copy Markdown
Owner

Summary

Agent-memory only. Follow-up to PR #587 (epic child #445), which is already merged into this integration branch. No production, test, or policy file is touched.

Records two durable findings from the #445 run, both correcting earlier memory that was pessimistic or incomplete.

The completion-gate receipt shape is no longer undiscoverable

Get-CheckpointAcknowledgedName in .claude/lib/orchestrator-state/OrchestratorStateRoutingContract.psm1 reads a hard-coded evidence member, so a skill or MCP receipt counts only when all three of these hold: its name is a non-blank string, its flag is boolean true (truthy is not enough), and it carries a non-blank evidence string.

Earlier runs guessed at alias key names (skills_used, mcp_receipts, mcp_tool_calls) and never supplied evidence, which is why the gate kept reporting the same receipts missing. That is why the prior memory concluded the shape was undiscoverable from outside the tool. It is discoverable — by reading the module rather than probing the validator.

The bug-route tool-name swap, and the divergence it creates

Get-ResolvedRequiredMcpTool swaps new_potential_entry for new_potential_bug_entry when the promotion type is bug. The MCP TypeScript surface does not apply that swap. Because required_mcp_tools is compared by exact list equality, no single list satisfies both validators on a bug route.

The hook is authoritative, so the guidance is to conform to it and expect two residual MCP errors that are divergence artifacts rather than missing work.

Together these supersede the earlier conclusion that --require-complete is simply unsatisfiable for a resumed-at-execution epic child. It is satisfiable at the real gate: .claude/hooks/validate-orchestrator-output.ps1 returns EXIT_CODE 0 on the #445 checkpoint.

collect_pr_context has two defects beyond misplacement

The existing entry recorded that the tool writes into the primary checkout. Two further defects are added, because they make the artifact unusable rather than merely misplaced: it reports GitHub CLI unavailable when gh is authenticated in the same worktree, and the primary checkout it writes into sits on a different branch, so the diff it computes is not the branch under review.

The remedy is therefore to author the PR body from real git data, not to copy the artifact into the worktree as the entry previously advised.

Verification

No GitHub Actions workflow runs on this pull request: .github/workflows/ci.yml triggers pull_request only on [main, development] and this PR targets the epic integration branch. The absence of checks is expected.

No toolchain stage is re-run, and none is required: the diff is three Markdown files under .claude/agent-memory/orchestrator/, which no build, analyzer, or test consumes. The C# toolchain result established for PR #587 against commit f912640b is unaffected.

Scope

  • Only .claude/agent-memory/orchestrator/** is modified — the one subtree the epic brief carves out of the .claude/** prohibition.
  • No rule, skill, hook, or config file is touched.
  • No production or test source is touched.

🤖 Generated with Claude Code

drmoisanand others added 2 commits August 22, 2026 12:04
…_pr_context defects
Two durable findings from epic child #445, both correcting earlier
memory that was pessimistic or incomplete.
The routing-contract completion gate's receipt shape is no longer
undiscoverable. Get-CheckpointAcknowledgedName in
.claude/lib/orchestrator-state/OrchestratorStateRoutingContract.psm1
reads a hard-coded 'evidence' member, so a skill or MCP receipt counts
only when its name is a non-blank string, its flag is boolean true, and
it carries a non-blank evidence string. Earlier runs guessed at alias
key names and never supplied evidence, which is why the gate kept
reporting the same receipts missing.
Get-ResolvedRequiredMcpTool swaps new_potential_entry for
new_potential_bug_entry on a bug route, and the MCP TypeScript surface
does not. Because required_mcp_tools is compared by exact list
equality, no single list satisfies both validators on a bug route. The
hook is authoritative, so conform to it and expect two residual MCP
errors.
Together these supersede the earlier conclusion that --require-complete
is simply unsatisfiable for a resumed-at-execution epic child: the real
termination gate now returns EXIT_CODE 0.
The collect_pr_context entry is expanded with two defects beyond
misplacement: it reports gh unavailable when gh is authenticated, and
the primary checkout it writes into sits on a different branch, so its
diff is not the branch under review. The remedy is to author the PR
body from real git data rather than to copy the artifact.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…m-foundation-integration' into bug/quickfiler-keyboard-action-contract-defects-445-exec
# Conflicts:
#	.claude/agent-memory/orchestrator/collect-pr-context-lands-in-main-checkout.md
@drmoisan
drmoisan merged commit 0bdad30 into epic/quickfiler-suite-determinism-foundation-integrationAug 22, 2026
drmoisan added a commit that referenced this pull request Aug 22, 2026
…nism
Confirms PR #591 (agent-memory only) reachable from the integration head
and issue #583 filed. Replaces the analyzer-skew finding with the measured
mechanism: packages.config pins Meziantou 3.0.174 / Roslynator 4.16.1 while
16 and 64 csproj Analyzer Include paths respectively still point at 3.0.156
and 4.16.0. CI is green only because _build-analyzers.yml declares
restore-keys fallback nuget-<os>-, which restores an older cache still
holding those directories. origin/main carries the identical skew, so the
final integration pull request is no worse than main, but it fails with
CS0006 the first time that cache entry is evicted.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UHj7wjLweuwfAP8NDA4iiP
Sign up for freeto 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.

1 participant

@drmoisan