Repository navigation
Open
Labels
agent/implementerAI implementer agentenhancementNew feature or requestphase/implementationImplementation phasetriage-requiredNeeds owner triage for priority decision
Description
Machine-Readable Contract
contract_schema_version: v1
issue_kind: implementation
parent_issue: "none"
goal_ref: "runtime_only VC が current repository-owned PreToolUse guard に決定論的に拒否される場合、semantic review まで持ち越さず deterministic contract review で早期に needs-fix として返し、refinement iteration を無駄に消費しない"
change_kind: workflow
dedupe_key: "issue-refinement:runtime-vc-pretool-guard-compatibility:v1"Parent Issue
none(Issue #2810 の refinement max-iteration 到達から発見した独立 recurrence-prevention follow-up)。
Parent Goal Ref
- Goal: executable VC として記載された runtime-only command が、実際の repository execution boundary では deterministic に拒否される false-ready を Step 2 で止める。
- Desired Destination: N/A(実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 自身の局所 contract 修正は 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 で行い、本 Issue は同 failure class の再発防止のみを所有する)。
Current Validated Scope
2026-09-28 current main eb7abf5dd44ac7475eb05f575cb6dcdbca3a45b9 と live #2810 / repository contract を確認した。
- 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 の latest
issue-refinement-loopは deterministic review が approve した後、Step 2.5 semantic review で AC11 の
env -u CLAUDE_GPT_PROXY_BIN bash scripts/claude-gpt/launch.sh --check-only
が.claude/hooks/secret_boundary_guard.shに exit 2 で拒否されることを検出した。 - 同 loop はその時点で canonical
max_iterations=3に到達しており、残 finding はrequires_owner_choice: falseなのにhuman_judgment_requiredで終了した。 - current
secret_boundary_guard.shは Bash command の先頭または shell separator 後のenvを fixed pattern で拒否する。対して
bash -c 'unset CLAUDE_GPT_PROXY_BIN; bash scripts/claude-gpt/launch.sh --check-only'
は同envpattern に一致しない。 - current
baseline_vc_preflight.pyは# preflight-scope: runtime_onlyを検出するとclassification=skipped/decision=goとして post-implementation runtime へ defer し、その literal command が current repository-owned PreToolUse guard により決定論的に拒否されるかを確認しない。 body-authoring.mdはruntime_onlymarker を compound/非-baseline command の正規 escape として許すが、「runtime_only でも current deterministic PreToolUse deny と互換である必要がある」という contract は materialize していない。- 調査: worktree isolation / secret boundary guard が secret-free診断まで過剰拒否する #2456 / 実装: secret-free Claude runtime diagnostic を literal-path helper として提供する #2471 は secret-free diagnostic と guard false-positive の回避を所有し、実装: worktree-agent-runtime-smoke に generic hook-chain evidence capability を追加する #2663 は generic hook-chain runtime evidence capability を所有する。本 Issue は guard を緩めず、Issue contract review が 既知の repository-owned deterministic deny を executable VC として approve しないことだけを所有するため duplicate ではない。
Remaining Parent Gaps
- 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 の AC11 command 自体の修正、および AC10 artifact consumer assertion は 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 で解消する。本 Issue の完了待ちにはしない。
- arbitrary Claude Code platform classifier / managed hook / user-level hook の静的再実装は行わない。
Outcome
# preflight-scope: runtime_only 付き VC でも、current repository-owned deterministic PreToolUse/Bash guard がその literal command を拒否することを secret-free synthetic input で再現できる場合は、baseline execution を行わず deterministic review が needs-fix を返し、guard-safe な command shape へ rewrite されてから semantic review に進む状態。
Runtime Verification Applicability
- decision: not_applicable
- reason: 本変更は repository-owned hook script に synthetic PreToolUse JSON を与える deterministic local check と focused pytest で完結し、Claude Code session / credential / network / external runtime を必要としないため。
In Scope
.claude/skills/issue-contract-review/scripts/baseline_vc_preflight.pyruntime_onlyを即skipped/goに確定する前に、VC の literal Bash command を current repository-owned.claude/hooks/secret_boundary_guard.shの synthetic secret-free PreToolUse input で評価する narrow compatibility check を追加する。- hook exit 2 の場合は VC 本体を実行せず、既存 result contract 内で deterministic
needs-fix/ blocking classification と fix hint を返す。 - hook exit 0 の場合は既存
runtime_onlyのskipped/gosemantics を維持する。 - hook 実行時に actual env dump / secret / credential / sensitive file を読み出さない。payload は
tool_name=Bashと Issue body 由来の literal command だけを含める。
.claude/skills/issue-contract-review/tests/- 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 の exact failure classを固定する focused regression を追加する。
env -u CLAUDE_GPT_PROXY_BIN bash scripts/claude-gpt/launch.sh --check-onlyは repository guard deny として non-go。bash -c 'unset CLAUDE_GPT_PROXY_BIN; bash scripts/claude-gpt/launch.sh --check-only'はこの guard check を通過し、従来どおり runtime_only defer される。- unrelated runtime_only command の既存 semantics を回帰させない。
.claude/skills/create-issue/references/body-authoring.md# preflight-scope: runtime_onlyは「baseline で実行しない」指定であり、current repository-owned deterministic PreToolUse deny を無視する免除ではないことを明記する。
Out of Scope
.claude/hooks/secret_boundary_guard.shの allowlist 緩和・pattern 変更。- Claude Code platform classifier、user/managed/plugin hook の挙動を repository 側で静的再実装すること。
- runtime VC を pre-implementation に実行すること。
- 新しい approval layer、persistent registry、generic shell policy engine の追加。
- 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 の runtime migration 実装・AC10/AC11 contract 修正。
- worktree-agent-runtime-smoke runner の機能拡張。
Acceptance Criteria
- AC1:
runtime_onlyVC の literal Bash command は、skipped/goを確定する前に current repository-ownedsecret_boundary_guard.shへ synthetic secret-free PreToolUse payload として渡され、hook exit 2 は deterministic non-go / needs-fix になる。VC command 自体は baseline で実行されない。 - AC2: 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 で late semantic blocker になった
env -u CLAUDE_GPT_PROXY_BIN bash scripts/claude-gpt/launch.sh --check-onlyfixture は、semantic review を必要とせず deterministic check で拒否される。 - AC3: guard-safe replacement
bash -c 'unset CLAUDE_GPT_PROXY_BIN; bash scripts/claude-gpt/launch.sh --check-only'fixture は guard compatibility check を通過し、従来のruntime_onlyskipped/goとverification_owner=impl-review-loop/runtime_verification_required=trueを維持する。 - AC4:
runtime_onlyでない既存 VC、ならびに guard exit 0 の既存 runtime_only VC の classification / baseline semantics を変更しない focused regression がある。 - AC5: synthetic hook check は Issue body 由来の literal command と固定
tool_name=Bash以外の secret/env value を payload に入れず、actual command execution、credential access、sensitive file read を行わない。 - AC6: hook script が unavailable / malformed / unexpected exit を返す場合は silent approve せず、既存 contract の fail-closed categoryへ写像する。新 schema family は追加しない。
- AC7:
body-authoring.mdはruntime_onlymarker が repository-owned deterministic PreToolUse deny の免除ではないことと、deny 時は guard-safe equivalent command shape へ rewrite することを明記する。 - AC8: issue-contract-review の既存 test suite が回帰しない。
Verification Commands
# AC1-AC6
# baseline-expect: fail
$ uv run --locked pytest .claude/skills/issue-contract-review/tests/test_runtime_vc_pretool_guard_compatibility.py -q
# AC7
# baseline-expect: fail
$ rg -n "runtime_only.*PreToolUse|PreToolUse.*runtime_only|deterministic.*guard" .claude/skills/create-issue/references/body-authoring.md
# AC8
$ uv run --locked pytest .claude/skills/issue-contract-review/tests/ -q
# AC7 / regression
$ uv run --locked pytest .claude/skills/create-issue/tests/ -qAllowed Paths
.claude/skills/issue-contract-review/scripts/baseline_vc_preflight.py.claude/skills/issue-contract-review/tests/.claude/skills/create-issue/references/body-authoring.md.claude/skills/create-issue/tests/
Stop Conditions
- Allowed Paths 外の変更が必要と判明した場合
- In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
- 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
- 後続 Phase / 別スコープへの波及が判明した場合
- nested SubAgent delegation が必要になった場合
- 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
- repository-owned hook を緩める必要がある場合は本 Issue で行わず、調査: worktree isolation / secret boundary guard が secret-free診断まで過剰拒否する #2456 / 実装: secret-free Claude runtime diagnostic を literal-path helper として提供する #2471 の既存 disposition と重複確認して別判断にする。
- current result schema に新規 key / enum が不可避な場合は、既存 category / blocker surface で表現できない根拠を示して停止する。
Required Skills
なし
Required Design References
.claude/skills/issue-refinement-loop/SKILL.md.claude/skills/issue-refinement-loop/references/semantic-design-review.md.claude/skills/issue-contract-review/scripts/baseline_vc_preflight.py.claude/skills/create-issue/references/body-authoring.md.claude/hooks/secret_boundary_guard.shdocs/dev/runtime-verification-policy.md- Issue 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 comment 5872128467
- Issue 調査: worktree isolation / secret boundary guard が secret-free診断まで過剰拒否する #2456 / 実装: secret-free Claude runtime diagnostic を literal-path helper として提供する #2471(related ownership boundary)
- Issue 実装: worktree-agent-runtime-smoke に generic hook-chain evidence capability を追加する #2663(hook-chain evidence capability。duplicate ではない)
Scope Delta(任意)
N/A
Related
- Source failure: 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 / 実装: Claude-GPT model/proxy 更新の runtime migration を完了工程に含め、人間介入を genuine blocker に限定する #2810 (comment)
- Related guard research: 調査: worktree isolation / secret boundary guard が secret-free診断まで過剰拒否する #2456
- Related literal diagnostic helper: 実装: secret-free Claude runtime diagnostic を literal-path helper として提供する #2471
- Related hook-chain evidence capability: 実装: worktree-agent-runtime-smoke に generic hook-chain evidence capability を追加する #2663
Metadata
Metadata
Assignees
Labels
agent/implementerAI implementer agentenhancementNew feature or requestphase/implementationImplementation phasetriage-requiredNeeds owner triage for priority decision
Activity