Skip to content

実装: impl-review-loop Step 5 の routing 判定を production consumer 化し shadow router test を廃止する #777

Closed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "#454"
goal_ref: "impl-review-loop Step 5 の production consumer を import 可能な実体として追加し、LOOP_VERDICT_V2.required_auto_actions[].kind|executor|skill と TEST_VERDICT_MACHINE/v1.branch_behind_main を shadow router ではなく本物の consumer 経路で fail-closed に検証できる状態にする"
change_kind: workflow

Parent Issue

#454

Parent Goal Ref

  • Goal: impl-review-loop の V2 routing boundary を docs/tests に登録しただけでなく、production consumer がその boundary を実際に消費して unknown / inconsistent input を fail-closed に扱う状態にする
  • Desired Destination: Step 5 routing regression が shadow 実装なしで production consumer を直接叩いて PASS する

Current Validated Scope

  • .claude/skills/impl-review-loop/scripts/ 配下に Step 5 routing 判定の importable consumer module を追加する
  • .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py の shadow helper を production consumer import ベースへ置き換える
  • .claude/skills/impl-review-loop/tests/test_termination_gate.py の shadow helper を production consumer import ベースへ置き換える
  • .claude/skills/impl-review-loop/tests/fixtures/step5_routing_consumer/ 配下に required_auto_actions.kind/executor/skill と branch_behind_main 整合を検証する fixture を追加する

Remaining Parent Gaps

Outcome

.claude/skills/impl-review-loop/scripts/ 配下の production consumer が required_auto_actions[].kind/executor/skill と TEST_VERDICT_MACHINE/v1.branch_behind_main を fail-closed に解釈し、対応する regression test が shadow 実装なしで PASS している状態。

In Scope

  • Step 5 routing 判定の共通 entrypoint を 1 箇所に実装する
  • required_auto_actions.kind/executor/skill の正規組み合わせを production consumer で判定し、unknown / missing / mismatched 値を fail-closed にする
  • TEST_VERDICT_MACHINE/v1.branch_behind_main と LOOP_VERDICT_V2.mergeability.merge_state_status の整合条件を production consumer で判定し、不一致を fail-closed にする
  • 既存 regression test をローカル helper 関数ではなく production consumer import ベースへ置き換える
  • fixture で BEHIND + update_branch、body-only required_auto_actions、branch_behind_main=true + CLEAN、branch_behind_main=false + BEHIND を固定する
  • route_loop_verdict_v2.py は import 時に副作用を持たず、gh/git/network/subprocess を呼ばない pure consumer module として実装する
  • required_auto_actions は array-of-objects のみを受け付け、string-list / V1 recommendations / camelCase は fail-closed または schema_invalid として扱う
  • apply_pr_review_fix_delta は pr-review-judge schema 外の action として fail-closed にする(許容しない)
  • LOOP_VERDICT_V2 schema と agent-skill-boundaries.md の boundary 定義を production consumer の正本とし、step-5-mergeability-handling.md の Bash snippet を参照しない

Out of Scope

  • GitHub REST pulls/{pull_number}/update-branch の呼び出し実装変更
  • implementation-worker の update_branch mode の write-side 挙動変更
  • expected_head_sha と current PR head の API レベル照合ロジックの実装
  • pr-review-judge producer 側 schema の追加変更
  • .claude/agents/test-runner.md の schema 追加変更
  • .claude/skills/impl-review-loop/steps/*.md の広範な wording 整理

Acceptance Criteria

  • AC1: .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py が追加され、import 時に副作用を持たず gh/git/network/subprocess を呼ばない pure consumer module である
  • AC2: route_loop_verdict_v2(loop_verdict, test_verdict=None) -> RouteDecision を public API として提供し、RouteDecision は route / fail_closed / reason_code / rerun_required / selected_action / errors フィールドを持つ
  • AC3: test_handoff_pr_hygiene_regression.py と test_termination_gate.py からローカル shadow helper(_evaluate_termination_route / _evaluate_route / _route_required_auto_action / ローカル ALLOWED_ACTION_KINDS)を削除し、production consumer import のみで routing 判定を行う
  • AC4: kind=update_branch / executor=implementation-worker / skill=implement-issue.update_branch / blocking_merge_ready=true / mechanical=true の正規 matrix のみが route_to_update_branch を返し、skill=implement-issue(サブコマンドなし)を含む欠落・未知・不一致はすべて fail-closed になる
  • AC5: required_auto_actions の kind / executor / skill / blocking_merge_ready / mechanical / expected_head_sha の missing / unknown / mismatched はすべて fail-closed reason_code を返す
  • AC6: TEST_VERDICT_MACHINE/v1.branch_behind_main と LOOP_VERDICT_V2.mergeability.merge_state_status の整合 invariant を実装する。true + BEHIND のみ behind とみなし、true + CLEAN、false + BEHIND、missing、非 bool、null、UNKNOWN、CONFLICTING、DIRTY、UNSTABLE、BLOCKED は auto update_branch route に入らない
  • AC7: required_auto_actions は array-of-objects のみ受け付け、string-list [update_branch]、V1 recommendations、camelCase mergeStateStatus は fail-closed または schema_invalid とする
  • AC8: tests/fixtures/step5_routing_consumer/ の fixture が positive case に加えて、wrong executor・wrong skill・skill=implement-issue(サブコマンドなし)・missing skill・unknown kind・apply_pr_review_fix_delta・body-only action・multiple actions・branch_behind_main 不整合を含む negative case を網羅する
  • AC9: rg -n "_evaluate_termination_route|_evaluate_route|_route_required_auto_action|ALLOWED_ACTION_KINDS" .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py が非ゼロ終了(shadow helper がテストファイルに残っていない)
  • AC10: uv run pytest .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py -v が PASS し、production consumer module の単体 test も node 指定で通る

Verification Commands

# AC1
$ test -f .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC2
$ rg -n "def route_loop_verdict_v2|class RouteDecision|fail_closed|reason_code|rerun_required|selected_action" .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC3
# preflight-scope: runtime_only
$ uv run pytest .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py -v

# AC4
$ rg -n "implement-issue\.update_branch|executor.*implementation-worker|kind.*update_branch|fail_closed|skill.*implement-issue[^.]" .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC5
$ rg -n "missing|unknown|mismatched|fail_closed|expected_head_sha|blocking_merge_ready|mechanical" .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC6
$ rg -n "branch_behind_main|merge_state_status|UNKNOWN|CONFLICTING|DIRTY|UNSTABLE|BLOCKED" .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC7
$ rg -n "array.of.objects|schema_invalid|string.list|recommendations" .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py

# AC8
$ rg -n "wrong_executor|wrong_skill|apply_pr_review_fix_delta|body.only|missing_skill|unknown_kind" .claude/skills/impl-review-loop/tests/fixtures/step5_routing_consumer

# AC9
$ rg -n "_evaluate_termination_route|_evaluate_route|_route_required_auto_action|ALLOWED_ACTION_KINDS" .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py

# AC10
# preflight-scope: runtime_only
$ uv run pytest .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py -v

Allowed Paths

  • .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py
  • .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py
  • .claude/skills/impl-review-loop/tests/test_termination_gate.py
  • .claude/skills/impl-review-loop/tests/fixtures/step5_routing_consumer/

Stop Conditions

  • Allowed Paths 外の変更が必要と判明した場合
  • In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
  • 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
  • 後続 Phase / 別スコープへの波及が判明した場合
  • nested SubAgent delegation が必要になった場合
  • 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
  • implementation-worker / GitHub update-branch API write-side 実装変更が必要と判明した場合

Required Skills

  • Python / pytest
  • YAML parsing
  • workflow routing contract review

Scope Delta(任意)

N/A

Runtime Verification Applicability

decision: not_applicable
reason: "Workflow consumer module and regression tests only. No runtime game behavior changed."

Delivery Rule

  • 1 Issue = 1 PR
  • Draft PR 既定
  • Refs #454 を PR 本文に含める
  • owner comment https://github.com/squne121/loop-protocol/issues/454#issuecomment-4661754386 を一次ソースとして扱う

Activity

  1. added
    phase/implementation
    agent/implementer
    enhancement
    on Jun 9, 2026
  2. squne121 commented on Jun 15, 2026

    @squne121
    OwnerAuthor

    総合判定: REQUEST_CHANGES

    #777 は方向性自体は正しいです。#454/#774 で「V2 routing boundary を docs/tests に登録する」までは進んだが、実テストは production consumer ではなく shadow helper を叩いており、executor / skill まで routing-critical と宣言した割に fail-closed 検証が弱い。その残タスクを production consumer 化として切り出したのが #777 です。#777 自体は open でコメントは 0 件、実装 PR は確認できていません。従ってこれは「実装前の Issue contract への敵対的レビュー」です。

    関連の流れとしては、#630 が LOOP_VERDICT_V2.merge_ready / required_auto_actions を導入し、#632 が APPROVE && merge_ready && required_auto_actions == [] を termination 条件に統一し、#454/#774 がそれを docs/tests に固定した。ただし #454 は producer/consumer 本体変更を Out of Scope にしていたため、real consumer が壊れていない保証は残っていません。#778 は update_branch の write-side executor を REST + expected_head_sha + classifier test で堅牢化する別スコープで、#777 はその前段の「誤った action を流さない consumer gate」です。

    Merge blocker 1: 現行テストは実装を守っていない

    現在の test_handoff_pr_hygiene_regression.py には _evaluate_termination_route() というローカル関数があり、コメントでも「テスト検証専用のローカル実装」「scripts/ への抽出は別 Issue」と明記されています。つまり regression test が production path ではなく、テスト内の shadow router の正しさを検証しているだけです。#777 の主目的はこの構造を消すことなので、単に route_loop_verdict_v2.py を追加するだけでは不十分で、既存 shadow helper の削除を AC と VC に明示すべきです。

    同じ問題は #454 の dedicated test にもあります。test_v2_routing_boundary_regression.py は ALLOWED_ACTION_KINDS と _route_required_auto_action() をテスト内に定義しており、production consumer ではなくローカル判定器を検証しています。この関数は kind と expected_head_sha だけを実質的に見ており、executor / skill の fail-closed 判定をしていません。

    Merge blocker 2: skill の正規値が既にズレている

    #777 の AC4 は kind=update_branch / executor=implementation-worker / skill=implement-issue.update_branch を正規組み合わせにしています。一方、既存 fixture v2_update_branch_behind.yml は skill: implement-issue です。これは軽微な表記差ではありません。skill を routing-critical field にするなら、implement-issue と implement-issue.update_branch は別値として扱い、前者は fail-closed に落とすべきです。

    さらに pr-review-judge 側の schema も skill: open-pr.update_pr | implement-issue.update_branch を明記しており、update_branch では expected_head_sha が必須です。#777 はこの schema を一次契約として採用し、古い fixture の implement-issue を互換許容してはいけません。互換許容した瞬間、skill を routing-critical と宣言した意味が消えます。

    Merge blocker 3: executor / skill を fail-closed にするテストが足りない

    現行 #454 test は positive case で executor == implementation-worker と skill == implement-issue を assert しているだけです。unknown kind と expected_head_sha guard はあるが、missing executor、unknown executor、missing skill、wrong skill、skill=implement-issue vs skill=implement-issue.update_branch、executor=pr-reviewer のような adversarial case は production route に入る可能性を検証していません。

    agent-skill-boundaries.md は LOOP_VERDICT_V2.required_auto_actions[].kind / executor / skill / expected_head_sha を routing-critical として登録し、unknown kind と missing/mismatched expected_head_sha は fail-closed としています。しかし executor / skill の negative rule が明文化されていないため、#777 側で補わないと「routing-critical と書いたが実際は読まない」状態になります。

    Merge blocker 4: Step 5 docs に V1/文字列リスト前提がまだ残っている

    step-5-feedback-and-termination.md は required_auto_actions を YAML array of objects として parse し、unknown kind/executor/skill、blocking_merge_ready != true、expected_head_sha 欠落を human escalation にする、としています。これは #777 の方向性と整合しています。

    しかし step-5-mergeability-handling.md 側は、Bash 抽出例で REQUIRED_AUTO_ACTIONS を [] または [update_branch] / [update_pr_body_hygiene] / [ensure_closing_keyword] として扱っています。これは array-of-objects schema と矛盾します。さらに BEHIND 分岐には recommendations: [update_branch] という V1 wording が残っています。#777 は「大幅な wording 再整理は Out of Scope」としていますが、production consumer の正本を作るなら、少なくともこの doc を executable source として参照しないことを明記しないと、実装者が誤って文字列リスト互換を再導入します。

    Merge blocker 5: branch_behind_main の invariant が狭すぎる

    #777 は branch_behind_main=true + CLEAN と branch_behind_main=false + BEHIND の fail-closed を AC5 に入れています。これは必要ですが十分ではありません。production consumer では以下も fail-closed にすべきです。

    branch_behind_main が missing、非 bool、文字列 "true"、null、または merge_state_status が UNKNOWN / UNSTABLE / BLOCKED / DIRTY / CONFLICTING のときに update_branch route が発火するケースです。Step 5 docs は merge state に CLEAN、UNSTABLE、BEHIND、BLOCKED、DIRTY、CONFLICTING、UNKNOWN を扱っているので、CLEAN/BEHIND の二点だけでは境界条件を網羅していません。

    Merge blocker 6: apply_pr_review_fix_delta の扱いが schema と衝突している

    #454 の shadow helper は ALLOWED_ACTION_KINDS に apply_pr_review_fix_delta を含めています。しかし pr-review-judge の required_auto_actions schema は ensure_closing_keyword | update_pr_body_hygiene | update_branch の 3 種を列挙しています。#777 が production consumer を作るなら、apply_pr_review_fix_delta を許容するのか、別 schema の action として拒否するのかを明示する必要があります。曖昧に許可すると、producer schema 外の action が consumer で通る fail-open になります。

    Web 調査に基づく実装上の注意

    update_branch は安全な “recommendation” ではなく、PR branch を更新する write operation です。GitHub REST の Update a pull request branch は base branch の HEAD を PR branch に merge し、GitHub App では head repository contents write、fine-grained token では Pull requests write permission が必要です。また expected_head_sha が PR head と一致しない場合は 422、通常の応答として 202/403/422 が定義されています。したがって consumer は update_branch action を厳格に検証し、少しでも schema が崩れたら #778 の executor へ渡す前に止めるべきです。([GitHub Docs]1)

    gh pr update-branch はデフォルトで base branch を PR branch に merge commit として取り込む挙動です。#777 自体は CLI/REST を呼ばない consumer scopeに限定すべきですが、だからこそ「この consumer は一切 gh / network / git を呼ばない」という無副作用制約を AC に入れるべきです。([GitHub CLI]2)

    GitHub REST は secondary rate limit でも 403/429 を返し、retry-after や x-ratelimit-reset に従わない継続リトライは integration ban につながり得ます。これは #778 の executor 側責務ですが、#777 の consumer が retry や API 呼び出しを持ち込むとスコープ破壊になります。([GitHub Docs]3)

    YAML は PR comment 由来の semi-untrusted input なので、production consumer は必ず yaml.safe_load 相当を使い、yaml.load を使ってはいけません。PyYAML 公式ドキュメントは untrusted source に対する yaml.load を unsafe と警告しています。

    pytest 側は .claude/skills/.../scripts 配下の importable module を読むため、import 経路も固定すべきです。pytest は test module / conftest import 時に sys.path や import mode の影響を受けるため、曖昧な path hack は shadow import や同名 module 衝突の温床になります。([pytest]4)

    #777 の AC はこう書き換えるべき

    現在の AC1-AC7 は概ね正しいが、検証の粒度が甘いです。以下まで上げないと、#454/#774 の二の舞になります。

    AC1: .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py は import 時に副作用を持たず、gh/git/network/subprocess を呼ばない pure consumer module である。
    
    AC2: public API として route_loop_verdict_v2(loop_verdict, test_verdict=None) -> RouteDecision を提供し、RouteDecision は route / fail_closed / reason_code / rerun_required / selected_action / errors を持つ。
    
    AC3: tests/test_handoff_pr_hygiene_regression.py と tests/test_termination_gate.py からローカル shadow helper を削除し、production consumer import のみで routing 判定を行う。
    
    AC4: 以下の正規 matrix のみ update_branch route を許可する:
      kind: update_branch
      executor: implementation-worker
      skill: implement-issue.update_branch
      blocking_merge_ready: true
      mechanical: true
      expected_head_sha == reviewed_head_sha
    
    AC5: kind / executor / skill / blocking_merge_ready / mechanical / expected_head_sha の missing / unknown / mismatched はすべて fail-closed reason_code を返す。
    
    AC6: TEST_VERDICT_MACHINE/v1.branch_behind_main と LOOP_VERDICT_V2.mergeability.merge_state_status は整合 invariant を持つ。
      true + BEHIND のみ behind とみなす。
      true + CLEAN、false + BEHIND、missing、non-bool、UNKNOWN、CONFLICTING、DIRTY は自動 update_branch route に入らない。
    
    AC7: required_auto_actions は array-of-objects のみ受け付け、string-list `[update_branch]`、V1 `recommendations`、camelCase `mergeStateStatus` は fail-closed または ignore + schema_invalid とする。
    
    AC8: fixture は positive だけでなく、wrong executor、wrong skill、skill=implement-issue、missing skill、unknown kind、apply_pr_review_fix_delta、body-only action、multiple actions、branch_behind_main 不整合を含む。
    
    AC9: `rg -n "def _evaluate_termination_route|def _route_required_auto_action|ALLOWED_ACTION_KINDS" .claude/skills/impl-review-loop/tests` が非ゼロ、またはそれらが production module 以外に存在しないことを VC に入れる。
    
    AC10: `uv run pytest .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py .claude/skills/impl-review-loop/tests/test_termination_gate.py -v` に加え、production consumer module 単体 test を node 指定で通す。
    

    推奨する consumer API

    route_loop_verdict_v2.py は Markdown 手順の再実装ではなく、workflow contract の小さな判定器にするべきです。

    @dataclass(frozen=True)
    class RouteDecision:
        route: Literal[
            "approved",
            "continue_loop",
            "route_to_update_branch",
            "route_to_body_only_action",
            "fail_closed",
        ]
        fail_closed: bool
        reason_code: str | None
        selected_action: dict[str, Any] | None
        rerun_required: dict[str, bool]
        errors: tuple[str, ...]
    
    def route_loop_verdict_v2(
        loop_verdict: Mapping[str, Any],
        test_verdict: Mapping[str, Any] | None = None,
    ) -> RouteDecision:
        ...

    理由は単純です。string route だけ返すと、fail_closed_expected_head_sha_guard と human_escalation と not_approved がテスト上は同じ “not update_branch” に潰れます。#777 が防ぎたいのは「たまたま route しなかった」ではなく、「なぜ route しなかったかを machine-readable に固定する」ことです。

    そのまま実装すると起きる失敗例

    最も危険なのは、既存 fixture の skill: implement-issue をそのまま正規値として通してしまうケースです。#777 の AC は implement-issue.update_branch を要求しているのに、既存 fixture は implement-issue です。この差分を吸収すると、将来 implement-issue.delete_branch や implement-issue.merge のような別 mode を誤って同一 skill とみなす余地ができます。

    次に危険なのは、merge_state_status == BEHIND だけで route_to_update_branch を返す実装です。required_auto_actions がない BEHIND、branch_behind_main=false の BEHIND、または expected_head_sha 欠落の BEHIND は、どれも update_branch executor に渡してはいけません。#778 側に TOCTOU guard があるとしても、consumer が壊れた payload を流してよい理由にはなりません。

    最後に、step-5-mergeability-handling.md の Bash snippet をそのまま production consumer の仕様として採用するのも危険です。そこでは required_auto_actions を文字列リスト的に扱っており、object schema の executor / skill / expected_head_sha を検証できません。#777 の production consumer は、この Markdown snippet ではなく LOOP_VERDICT_V2 schema と boundary doc を正本にすべきです。

    Issue #777 に投稿するレビューコメント案

    REQUEST_CHANGES: この Issue は方向性は正しいですが、現行 AC では #454/#774 の shadow router 問題を完全には潰せません。
    
    特に `skill` の正規値を `implement-issue.update_branch` に固定してください。既存 fixture には `skill: implement-issue` が残っていますが、`skill` を routing-critical とする以上、これは互換許容ではなく fail-closed 対象です。
    
    また、`executor` / `skill` を routing-critical と宣言しているのに、negative fixture が `unknown kind` と `expected_head_sha` に偏っています。missing/wrong executor、missing/wrong skill、`skill=implement-issue`、`apply_pr_review_fix_delta`、string-list `required_auto_actions: [update_branch]`、V1 `recommendations` をすべて fail-closed fixture に入れてください。
    
    VC には、test files 内の `_evaluate_termination_route` / `_route_required_auto_action` / local `ALLOWED_ACTION_KINDS` が消えていることを確認する grep を追加してください。production consumer import に置き換えただけでなく、shadow implementation が残っていないことを機械的に検証する必要があります。

    結論

    #777 は実装すべきですが、現状の contract のままでは「shadow helper を別ファイルに移しただけ」の PR が通ります。合格条件は、route_loop_verdict_v2.py というファイルの存在ではなく、LOOP_VERDICT_V2.required_auto_actions と TEST_VERDICT_MACHINE/v1.branch_behind_main の不正入力を production consumer が理由付きで fail-closed に落とすことです。特に skill=implement-issue を許容しないこと、executor / skill の negative test を追加すること、Step 5 docs の V1/string-list wording に引きずられないことが merge-ready の最低ラインです。

  3. squne121 commented on Jun 15, 2026

    @squne121
    OwnerAuthor

    Refinement Loop: Approved

    The issue has been approved and is ready for implementation.

  4. squne121 commented on Jun 15, 2026

    @squne121
    OwnerAuthor

    CONTRACT_REVIEW_RESULT_V1

    schema: CONTRACT_REVIEW_RESULT_V1
    issue_number: 777
    status: go
    generated_at: "2026-06-15T13:10:00Z"
    body_sha256: "sha256:adf018ca9b3c6b1ac97c07ba1b58003c8e34328dc30613a3d1d166aa07aa4a7d"
    
    outcome: |
      .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py を production consumer module として追加し、
      test_handoff_pr_hygiene_regression.py と test_termination_gate.py の shadow helper を production consumer import ベースへ置き換え、
      fixtures/step5_routing_consumer/ に positive/negative fixture を追加して regression test が PASS する状態にする。
    
    worktree: .claude/worktrees/issue-777-route-loop-verdict-v2
    branch: worktree-issue-777-route-loop-verdict-v2
    
    checks:
      template_compliance: pass
      state_label: pass  # state/needs-human なし
      allowed_paths_present: pass
      vc_present: pass
      stop_conditions_complete: pass
      ac_verifiability: pass
      product_spec_check:
        applicability: not_applicable
        decision: pass
      worktree_branch_collision: pass  # issue-777 worktree/branch 未存在
      blockers: pass  # no blockers
      next_action: implement-issue
    
      vc_preflight:
        status: go  # preflight blocked→go に手動昇格(下記理由)
        summary:
          expected_fail: 1    # AC1: route_loop_verdict_v2.py 未存在 → expected
          human_judgment: 6   # AC2,AC4-AC8: rg on non-existent file (exit 2) → expected_fail at baseline → go
          unexpected_pass: 1  # AC9: negative-check VC / shadow helpers が baseline で存在 → baseline pass 期待 → go
          skipped: 2          # AC3,AC10: runtime_only → deferred to post-implementation
    
        manual_overrides:
          - acs: [AC2, AC4, AC5, AC6, AC7, AC8]
            original: human_judgment
            override: expected_fail
            reason: "rg exits 2 (file not found) for route_loop_verdict_v2.py which does not exist at baseline. Expected at baseline."
          - acs: [AC9]
            original: unexpected_pass
            override: go
            reason: >
              AC9 は negative-check VC (rg exits non-zero = helpers removed = success)。
              baseline では shadow helpers が存在するため rg exits 0。
              この baseline pass は実装前に期待される挙動であり、# baseline-expect: pass アノテーション相当。
    
      blocked_reasons: []
      runtime_verification_applicability: not_applicable
    
    allowed_paths:
      - .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py
      - .claude/skills/impl-review-loop/tests/test_handoff_pr_hygiene_regression.py
      - .claude/skills/impl-review-loop/tests/test_termination_gate.py
      - .claude/skills/impl-review-loop/tests/fixtures/step5_routing_consumer/
    
    acceptance_criteria_count: 10
    required_skills:
      - Python / pytest
      - YAML parsing
      - workflow routing contract review
    
    delivery_rule:
      pr_per_issue: 1 Issue = 1 PR
      draft: true
      refs: "Refs #454"
  5. added 2 commits that reference this issue on Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/implementerenhancementphase/implementation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions