Repository navigation
Closed
Labels
agent/implementerAI implementer agentenhancementNew feature or requestphase/implementationImplementation phase
Description
Machine-Readable Contract
contract_schema_version: v1
issue_kind: implementation
parent_issue: "none"
goal_ref: "PR #1560(Closes #1547)レビューで pr-reviewer が指摘した command_registry.py の argv テンプレート陳腐化を解消する"
change_kind: codeParent Issue
なし(単独改善)
Parent Goal Ref
- Goal: scope_rollup.run の registry エントリが、実際の executor が要求する argv 形状を正しく docs/SSOT として反映する
- Desired Destination: command_registry.py の scope_rollup.run argv テンプレート更新のみで完結する単独改善(parent tracker なし)
Current Validated Scope
- .claude/skills/issue-refinement-loop/scripts/command_registry.py の scope_rollup.run エントリの argv テンプレート定義を更新する
- 対応する既存テスト(.claude/skills/issue-refinement-loop/tests/test_command_registry.py 等)に、更新後の argv 形状を検証するテストケースを追加または更新する
Remaining Parent Gaps
なし
Outcome
command_registry.py の scope_rollup.run エントリの argv テンプレートが、実際の executor(scripts/agent-guards/run_scope_rollup_preflight.py)が要求する現行の argv 形状(--invocation-id / --requested-at を含む)と一致した状態になり、対応するテストが PASS している状態。
In Scope
- command_registry.py の REGISTRY["scope_rollup.run"]["argv"] を、--issue-number / --repo に加えて --invocation-id / --requested-at プレースホルダを含む形状に更新する
- 新規プレースホルダ(invocation_id / requested_at)の placeholders 定義(型・required)を追加する
- 上記変更を検証するテストケースの追加・更新
- Verification Commands の read-only assertion を contract-review allowlist に適合する
rg -nに正規化する
Out of Scope
- scope_rollup.run を skill_runtime_exec.py の registry SSOT 経路へ統合すること(別 Issue で扱う。P1-5 follow-up)
- scripts/agent-guards/run_scope_rollup_preflight.py 本体のロジック変更
- local_main_branch_guard.py / skill_runtime_command_policy.py の dispatch ロジック変更
Acceptance Criteria
- AC1: command_registry.py の scope_rollup.run エントリの argv に --invocation-id トークンが含まれる
- AC2: command_registry.py の scope_rollup.run エントリの argv に --requested-at トークンが含まれる
- AC3: command_registry.py の scope_rollup.run エントリの placeholders に invocation_id / requested_at が定義されている
- AC4: 既存の command_registry.py 関連テストスイートが PASS する
Verification Commands
# AC1
# baseline-expect: fail
$ rg -n -- "invocation-id" .claude/skills/issue-refinement-loop/scripts/command_registry.py
# AC2
# baseline-expect: fail
$ rg -n -- "requested-at" .claude/skills/issue-refinement-loop/scripts/command_registry.py
# AC3
# baseline-expect: fail
$ rg -n -- "invocation_id" .claude/skills/issue-refinement-loop/scripts/command_registry.py
# AC4
$ uv run --locked pytest .claude/skills/issue-refinement-loop/tests/test_command_registry.py -vAllowed Paths
.claude/skills/issue-refinement-loop/scripts/command_registry.py.claude/skills/issue-refinement-loop/tests/test_command_registry.py
Stop Conditions
- Allowed Paths 外の変更が必要と判明した場合
- In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
- 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
- 後続 Phase / 別スコープへの波及が判明した場合
- nested SubAgent delegation が必要になった場合
- 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
Required Skills
なし
Required Design References
- docs/dev/hook-boundaries.md#12c-scope_rollup-run-の位置づけissue-1547
Scope Delta(任意)
該当なし。
Source(起票元の参照情報)
- 重複排除キー(dedupe_key): "follow-up:squne121/loop-protocol:pr/1560:1"
- 関連プルリクエスト: 実装: scope-rollup の absolute tmp artifact export を local guard で許可する (Closes #1547) #1560
- 関連Issue: 実装: scope-rollup の absolute tmp artifact export を local guard で許可する #1547
- 背景: PR 実装: scope-rollup の absolute tmp artifact export を local guard で許可する (Closes #1547) #1560 レビューで pr-reviewer が指摘した非ブロッキング所見(command_registry.py の scope_rollup.run argv テンプレートが --invocation-id/--requested-at を含まない旧形状のまま)の follow-up
Runtime Verification Applicability
- decision: not_applicable
- reason: registry argv / placeholder contract と unit test の更新だけを扱い、外部 runtime transaction は 調査: scope_rollup.run exact executor を registry SSOT 経路(skill_runtime_exec 相当)へ統合すべきか検討する #1580 の implementation Issue で扱う。
Metadata
Metadata
Assignees
Labels
agent/implementerAI implementer agentenhancementNew feature or requestphase/implementationImplementation phase
Activity
squne121 commentedon Jul 18, 2026
Scope Overlap Preflight (C1): 以下の OPEN issue と Allowed Paths が重複しています。
related_issue: #1555, #1007, #1006, #998, #997, #995, #944, #926
overlapping_paths: .claude/skills/issue-refinement-loop/scripts/command_registry.py, .claude/skills/issue-refinement-loop/tests/test_command_registry.py
non_conflict_reason: 上記候補はいずれも .claude/skills/issue-refinement-loop/scripts または tests ディレクトリ全体を広く Allowed Paths に含むだけの既存 issue であり、本 issue が対象とする scope_rollup.run の argv テンプレート更新という具体的な編集意図とは一致しません。#1555 は parent_replay_binding.py 関連の別機能追加、#1007/#1006/#997/#944/#926 は loop state / preflight 関連の広範な変更です。
edit_intent: command_registry.py の REGISTRY["scope_rollup.run"]["argv"] エントリ 1 箇所のみに --invocation-id / --requested-at プレースホルダを追加する、局所的かつ小規模な変更です。
dependency ordering: 上記候補との明示的な依存関係はありません。並行して進める場合はマージコンフリクトのリスクを軽減するため、先にマージされた方に追従してリベースします。
ISSUE_OVERLAP_PREFLIGHT_RESULT_V1: decision=overlap_requires_comment, reason_code=allowed_paths_overlap, policy_class=C1 (check_issue_overlap.py 出力より)
squne121 commentedon Jul 18, 2026
Contract repair
git grepを contract-review allowlist に含まれるrg -nへ置換しました。squne121 commentedon Jul 18, 2026
Contract Review Result
feat: scope rollup registry invocation metadata (#1579) (#1594)