Skip to content

実装: ensure_contract_snapshot.py の find_latest_go が stale go コメントを fresh として誤判定するバグを修正する #1445

Closed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "none"
goal_ref: "ensure_contract_snapshot.py が stale な go コメントを current body 用の existing_go として再利用せず、helper の直接実行で fresh snapshot を一度だけ materialize できるようにする"
change_kind: code

Parent Issue

なし(単独改善)

Parent Goal Ref

  • Goal: ensure_contract_snapshot.py の直接実行(check-only / auto / dry-run)における stale go 判定を一貫して fail-closed にする。
  • Desired Destination: 現在の Issue 本文に対応する canonical な body_sha256 を持つ go コメントだけを existing snapshot として採用し、それ以外は stale として扱う状態。

Current Validated Scope

  • ensure_contract_snapshot.py 内で、初回の existing-go 採用と投稿直前の dedupe の両方に共通 freshness 判定を適用する。
  • existing-go 採用前の Issue snapshot 再確認を bounded retry 1 回に限定して追加し、再確認中にも本文または更新時刻が変化した場合は stale_or_conflicting_snapshot で終了する。
  • helper 単体の直接実行だけを修正対象とし、capsule-first の loop preparation 方針は変更しない。

Remaining Parent Gaps

なし

Outcome

.claude/skills/impl-review-loop/scripts/ensure_contract_snapshot.py が、body_sha256 の canonical 形式と現在の Issue 本文への完全一致を満たす go コメントだけを existing_go として採用する状態。stale または不正な hash の go コメントは、check-only では ok にせず、auto / dry-run では fresh review の materialization 経路へ進む。auto --post は投稿直前にも stale go が残っていても fresh コメントを一度投稿し、再確認中の本文変更は bounded retry 後に stale_or_conflicting_snapshot で終了する。対応する pytest 回帰テストが PASS する。

In Scope

  • ensure_contract_snapshot.py に、inner.body_sha256 が sha256: に続く 64 桁小文字 16 進数であり、期待する本文 hash と完全一致する場合だけ true を返す共通 freshness helper を追加し、欠落・null・空・非文字列・大文字・空白・形式不正を stale として扱う。
  • 初回の go_result と投稿直前の go_post の両方で共通 helper を用い、fresh go だけを existing_go / deduped_existing として採用する。
  • 初回 existing-go 採用前に body / updatedAt を再取得する。初回 snapshot と不一致ならコメントを再取得して判定を 1 回だけやり直し、再試行でも変化した場合は stale_or_conflicting_snapshot を返す。
  • test_ensure_contract_snapshot.py に fresh / stale / invalid hash、auto --post の stale-go 再採用防止、投稿直前の fresh-go dedupe、existing-go 判定中の本文変化、既存の blocked precedence・idempotency・materialization 中本文変更を検証する回帰テストを追加する。
  • 少なくとも 1 件、実際の parse_contract_review_results() と find_latest_go() を通して parser consumer 境界を検証するテストを追加する。

Out of Scope

  • run_contract_review_once.py、contract_review_result_parser.py、build_intake_capsule.py、impl-review-loop のスキル本文、または preparation policy の変更。
  • capsule-first の stale snapshot 停止方針を stale 自動復旧へ変更すること。
  • コメント投稿者 identity、author_association、編集済みコメントの信頼境界、時刻 provenance の producer trust policy。必要なら別 Issue とする。
  • _IDEMPOTENCY_MARKER_TEMPLATE の形式または既存 marker による重複投稿防止契約の変更。

Acceptance Criteria

  • AC1: canonical な body_sha256 が現在本文と一致する existing go は、review / post を呼ばず status: ok、source: existing_go を返す。
  • AC2: hash が不一致、欠落、null、空、非文字列、形式不正、大文字、または空白を含む existing go は stale として扱い、check-only で ok を返さない。
  • AC3: stale go がある auto / no-post と dry-run は fresh review を実行し、dry_run_would_post を返す。
  • AC4: stale go が投稿直前にも残る auto --post は stale go を dedupe せず fresh コメントを一度投稿する。
  • AC5: 投稿直前に現在本文 hash と一致する go が現れた場合だけ deduped_existing を返す。
  • AC6: existing-go 採用前の再確認で本文または updatedAt が変化した場合は 1 回だけ再試行し、再試行中にも変化した場合は stale_or_conflicting_snapshot を返す。
  • AC7: latest_blocked precedence、idempotency marker、materialization 中の本文変更に対する既存の安全保証を維持する。
  • AC8: 実 parser の parse_contract_review_results() と find_latest_go() を通すテストを含め、対象 pytest 全件が PASS する。

Verification Commands

# AC1
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_existing_go_matches_current_body_returns_ok -v
# AC2
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_invalid_or_stale_go_never_returns_existing_go -v
# AC3
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_stale_go_auto_without_post_materializes_dry_run -v
# AC4
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_stale_go_at_post_check_does_not_dedupe -v
# AC5
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_fresh_go_at_post_check_dedupes -v
# AC6
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_existing_go_snapshot_change_retries_then_conflicts -v
# AC7
# baseline-expect: pass
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -v
# AC8
# preflight-scope: pr_review_only
$ uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_parser_result_with_canonical_body_sha256_is_consumed -v

Allowed Paths

  • .claude/skills/impl-review-loop/scripts/ensure_contract_snapshot.py(freshness と bounded atomicity 修正)
  • .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py(回帰テスト)

Runtime Verification Applicability

decision: not_applicable
reason: Python orchestration helper と unit test のみを変更し、ゲームの DOM、Canvas、state、render の runtime 挙動には影響しない。

Stop Conditions

  • Allowed Paths 外の変更が必要と判明した場合
  • In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
  • 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
  • 後続 Phase / 別スコープへの波及が判明した場合
  • nested SubAgent delegation が必要になった場合
  • 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
  • capsule-first の stale snapshot 停止方針またはコメント producer の trust policy を変更する必要が判明した場合
  • bounded retry を超える再試行または既存 safety invariant の緩和が必要になった場合

Required Skills

  • なし

Required Design References

  • .claude/skills/impl-review-loop/SKILL.md(contract snapshot と impl-review-loop の handoff 境界)
  • .claude/skills/impl-review-loop/scripts/ensure_contract_snapshot.py(B2 atomicity と idempotency の既存契約)
  • .claude/skills/impl-review-loop/steps/preparation.md(capsule-first の stale snapshot 停止方針)
  • .claude/skills/issue-contract-review/scripts/contract_review_result_parser.py(parser 出力と find_latest_go() の責務)

Scope Delta(任意)

ユーザー決定により、helper 単体の直接実行修正に限定する。build_intake_capsule.py と preparation policy は変更しない。

Background

Issue #1431 / PR #1438 の review iteration で、本文編集後の stale go が ensure_contract_snapshot.py --mode auto --post により existing go として再利用され、fresh go が投稿されない不具合を確認した。原因は initial existing-go 採用と投稿直前の dedupe がともに hash freshness を確認しないことにある。本 Issue は helper の直接実行を決定論的に修正し、impl-review-loop 全体の stale 自動復旧方針には変更を加えない。

Activity

  1. added
    phase/implementation
    agent/implementer
    enhancement
    on Jul 11, 2026
  2. squne121 commented on Jul 11, 2026

    @squne121
    OwnerAuthor

    敵対的レビュー結果

    判定

    REQUEST_CHANGES — implementation-ready: false

    不具合の再現、原因の大枠、修正対象ファイルは妥当です。ただし、Issue #1445 の記載どおり「最初の go_result 短絡判定」だけを修正しても、主要ユースケースである --mode auto --post は直りません。

    また、現在の impl-review-loop が定める stale snapshot の停止方針と、Issue #1445 が目指す自動再生成方針の境界も曖昧です。


    Blocker 1 — 投稿直前に同じ stale go を再採用する

    現行処理には find_latest_go() の呼び出しが2か所あります。

    1. 初回コメント取得後
    2. fresh review 実行後、投稿直前の atomicity check

    Issue #1445 は1か所目だけを変更対象としています。しかし2か所目は、再取得したコメントに go が1件でもあれば、body hash を確認せず existing_go / deduped_existing を返します。

    したがって次の順序になります。

    stale go を検出
    → 初回短絡を回避
    → run_contract_review_once() で fresh go を生成
    → 投稿直前にコメントを再取得
    → 以前からある stale go を再び find_latest_go()
    → deduped_existing として終了
    → fresh go は投稿されない
    

    これは Issue の Background にある実障害をそのまま残します。

    必須修正

    freshness 判定を共通関数化し、少なくとも両方の採用地点に適用すべきです。

    def is_go_fresh(go_result: dict | None, expected_body_sha256: str) -> bool:
        if not go_result:
            return False
    
        inner = go_result.get("inner")
        return (
            isinstance(inner, dict)
            and isinstance(inner.get("body_sha256"), str)
            and inner["body_sha256"] == expected_body_sha256
        )

    投稿直前の go_post は、body_sha256_post と一致する場合だけ dedupe し、不一致なら投稿処理を継続する必要があります。


    Blocker 2 — 「現在の Issue 本文」との一致を保証できない

    初期 snapshot は実際には単一の atomic read ではありません。

    fetch_issue_snapshot() で body / updatedAt を取得
    → 別 API 呼び出しで comments を取得
    → existing go を即時採用
    

    この間に Issue 本文が更新された場合、古い本文の hash と古い go が一致していても、処理終了時点の最新本文に対しては stale です。existing-go 経路には投稿前のような再取得比較がありません。

    Issue の Desired Destination は「現在の Issue 本文の実際の sha256」との一致を要求しているため、現在の Allowed Paths 内でも atomicity 処理を変更する必要があります。しかし、Issue は B2 atomicity の変更を明示的に Out of Scope としています。これは契約矛盾です。

    必須修正

    次のどちらかを固定してください。

    • existing-go 採用前に body / updatedAt を再取得し、最初の値と一致する場合だけ ok にする
    • 変更を検出したら1回だけ bounded retry し、再度変化した場合は stale_or_conflicting_snapshot にする

    「初回の hash 比較だけ」にスコープを狭めるなら、Outcome から「現在の本文を保証する」という表現を削る必要があります。


    Blocker 3 — impl-review-loop の現行 stale 方針と整合していない

    標準フローは capsule-first です。build_intake_capsule.py は stale go を検出すると refresh_contract_snapshot に route し、preparation はそこで停止する設計です。

    preparation.md も、body hash 不一致または legacy snapshot の時刻不一致を stale_contract_review とし、人間に issue-contract-review の再実行を依頼すると定めています。

    一方、Issue #1445 は stale go を mode:auto で自動再生成・投稿することを要求しています。さらに build_intake_capsule.py は hash 欠落時に時刻フォールバックで go を採用できるため、「hash 一致時のみ fresh」という #1445 の方針とも split-brain になります。

    必須判断

    • helper 単体の直接実行バグを直すだけ
      Outcome と Goal を ensure_contract_snapshot.py 単体の挙動に限定する。
    • impl-review-loop が stale から自動復旧するところまで直す
      build_intake_capsule.py、preparation policy、対応テストを Scope と Allowed Paths に追加する。

    現状は後者を主張しながら、変更範囲は前者に留まっています。


    Major 1 — hash 欠落・型不正の扱いが未定義

    共有 parser が valid と判定する必須項目には body_sha256 が含まれていません。status、generated_by、generated_at、issue_url が有効なら hash がなくても結果に入ります。

    既存テストの _GO_COMMENT にも body_sha256 がなく、test_existing_go_returns_ok はそのコメントを fresh として受理しています。

    Issue の「一致する場合のみ existing_go」という文言に従うなら、以下はすべて stale または unusable とすべきです。

    • body_sha256 欠落
    • null
    • 空文字
    • sha256: 形式でない値
    • 非文字列
    • 大文字・空白など canonical format 外

    既存 hashless fixture をそのまま維持すると false green になります。


    Major 2 — mock が parser-consumer 契約を隠す

    現在の _mock_parser_mod() が生成する go result には inner がありません。実 parser は inner に body_sha256 を格納しますが、テスト double はその構造を再現していません。

    今回の不具合はまさに parser の出力フィールドを consumer が正しく使わない問題です。すべてを MagicMock にすると、実 parser との結合部分を検証できません。

    少なくとも1件は、実際の parse_contract_review_results() と find_latest_go() を通す統合寄りの unit test が必要です。


    Major 3 — Issue タイトルの責務帰属が不正確

    find_latest_go() は、仕様どおり「status が go のうち最新の結果」を返しているだけです。freshness の検証を担当するとは定義されていません。

    実際の defect は、ensure_contract_snapshot() がその結果を無条件で採用している点です。

    推奨タイトル:

    実装: ensure_contract_snapshot.py が stale go コメントを existing_go として再利用するバグを修正する

    parser の責務を不必要に拡張する実装を防げます。


    セキュリティ上の follow-up

    parser はコメント本文中の自己申告 generated_by: issue-contract-review を検査しますが、コメント投稿者の identity は検査しません。また、comments fetch の projection は user や author_association を捨てています。

    GitHub の API は投稿者、association、作成・更新日時を返し、既存コメントの編集も可能です。したがって body hash は「特定本文との対応」は証明しますが、「信頼された producer が生成した」ことまでは証明しません。 ([GitHub Docs]1)

    これは #1445 の最小修正を止める必要まではありませんが、別 Issue で以下を固定すべきです。

    • trusted producer の user.login または GitHub App identity
    • author_association の扱い
    • 編集済みコメントを許可するか
    • created_at、updated_at、generated_at の整合性

    必須テスト行列

    最低限、以下を Acceptance Criteria に追加すべきです。

    1. hash 一致の existing go は即時 ok。review/post は呼ばれない。
    2. hash 不一致 + check-only は ok を返さない。
    3. hash 不一致 + auto/no-post は review を実行し dry_run_would_post。
    4. hash 不一致 + auto/post で、投稿直前にも同じ stale go が残っていても fresh comment を1回投稿する。
    5. 投稿直前に current hash と一致する別 go が出現した場合だけ dedupe。
    6. hash 欠落・型不正は fail-closed。
    7. body 取得と comments 取得の間に Issue が更新された場合、existing go を ok にしない。
    8. latest blocked precedence、materialization 中の body change、idempotency marker の既存保証を維持する。

    特に4番が、今回の実障害を閉じる決定的な回帰テストです。


    関連履歴の評価

    発見経路として記載された #1431 / PR #1438 では、Scope Delta 後の snapshot stale が実際にレビュー blocker となり、その後 current body hash と fresh go hash の一致を再確認しています。Issue #1445 の問題提起には十分な実証があります。

    同一問題を扱った #1447 は #1445 との重複として既に closed/duplicate に整理されています。canonical Issue を #1445 に一本化した判断は妥当です。

    最終評価

    • 不具合の存在: 確認済み
    • 初回短絡判定の修正方針: 部分的に正しい
    • auto --post の修復: 未達
    • snapshot atomicity: 契約不足
    • impl-review-loop 全体との整合: 未確定
    • 回帰テスト: 主要経路不足

    Blocker 1〜3を修正し、特に投稿直前の stale go 再採用テストを追加するまでは、実装着手不可と判断します。

  3. squne121 commented on Jul 11, 2026

    @squne121
    OwnerAuthor

    Refinement Loop: Human Escalation Required

    The loop has terminated and requires human review. Cause: human judgment required

    Blockers

    "OWNER コメントが、helper 単体の直接実行修正に限定するか、impl-review-loop 全体の stale 自動復旧まで含めるかの選択を要求している"
    
    "現行 Issue は後者の成果を主張する一方で、Allowed Paths と Out of Scope は前者に留まり、契約が矛盾している"
    
    "既存 go 採用前および投稿直前の両方で freshness と atomicity を扱う必要があり、B2 atomicity を Out of Scope とする現契約のままでは完了条件を満たせない"
    
    "scope_signal_guard_triggered"
    
    "scope_signal_guard_reason_code:requires_issue_split"
    
  4. squne121 commented on Jul 11, 2026

    @squne121
    OwnerAuthor

    Contract Review Result

    CONTRACT_REVIEW_RESULT_V1:
      status: go
      generated_at: "2026-07-11T03:33:58Z"
      generated_by: issue-contract-review
      issue_url: https://github.com/squne121/loop-protocol/issues/1445
      body_sha256: "sha256:654f894b8aec3128f23387deac2f9a58e629c7b96b3dbafac99471fe32c3482a"
      checks:
        readiness: go
        blockers: pass
        product_spec: pass
        vc_preflight: pass
      source: ensure_contract_snapshot_auto
  5. squne121 commented on Jul 11, 2026

    @squne121
    OwnerAuthor

    Contract Review Result

    CONTRACT_REVIEW_RESULT_V1:
      status: go
      generated_at: "2026-07-11T04:49:59Z"
      generated_by: issue-contract-review
      issue_url: https://github.com/squne121/loop-protocol/issues/1445
      body_sha256: "sha256:654f894b8aec3128f23387deac2f9a58e629c7b96b3dbafac99471fe32c3482a"
      checks:
        readiness: go
        blockers: pass
        product_spec: pass
        vc_preflight:
          decision: pass
          classifications: [{"ac":"AC1","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_existing_go_matches_current_body_returns_ok -v","command_hash":"sha256:9e095d95f0a74d99bd1f9d7c58d8ee1c770e091aa41ba23ababe08bb03bcd817","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC2","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_invalid_or_stale_go_never_returns_existing_go -v","command_hash":"sha256:6658e0bae0d938c11c5eb660c5b8e4dcd9a9c266b557c66b25f93e86344ef304","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC3","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_stale_go_auto_without_post_materializes_dry_run -v","command_hash":"sha256:801e5c9f4b911591e441ffd2f45583e683442d4618573d31aefba6175af29d3d","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC4","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_stale_go_at_post_check_does_not_dedupe -v","command_hash":"sha256:aac00e9ed420646f16b3c04e59c0025c3e303eb90749bfd4b40d4b5441def822","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC5","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_fresh_go_at_post_check_dedupes -v","command_hash":"sha256:7d9b7fd50c34cd34a34fab163f4efbaa68114349b82689dbbc47f5586bc283c4","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC6","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_existing_go_snapshot_change_retries_then_conflicts -v","command_hash":"sha256:c210fad78f3e1b803b01a327bd30eaa4043d7d8fa056e70d10b38b85c6e641f8","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false},{"ac":"AC7","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -v","command_hash":"sha256:9c5abe0f9f1d339b5170bf1203af786e031b850805d592271d79b207bc3d64f6","runner":"exec","exit_code":0,"classification":"expected_pass","category":"baseline_expect_pass","decision":"go","scope_class":"regression_gate","confidence":"low","stdout_head":["============================= test session starts ==============================","platform linux -- Python 3.12.3, pytest-9.0.3, pluggy-1.6.0 -- /home/squne/projects/LOOP_PROTOCOL/.claude/worktrees/issue-1445-stale-go-freshness/.venv/bin/python","cachedir: .pytest_cache","rootdir: /home/squne/projects/LOOP_PROTOCOL/.claude/worktrees/issue-1445-stale-go-freshness","configfile: pyproject.toml","plugins: xdist-3.8.0","collecting ... collected 48 items",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestCheckOnlyMode::test_existing_go_matches_current_body_returns_ok PASSED [  2%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestCheckOnlyMode::test_no_go_returns_human_judgment PASSED [  4%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestCheckOnlyMode::test_latest_blocked_returns_blocked_needs_refinement PASSED [  6%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[None] PASSED [  8%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[] PASSED [ 10%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[1] PASSED [ 12%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[sha256:AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA] PASSED [ 14%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa] PASSED [ 16%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[ sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa] PASSED [ 18%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_invalid_or_stale_go_never_returns_existing_go[sha256:375af32c999cd2f11e63c380e9b5467cc2c61ddf97c0b34d9a9659217a406490] PASSED [ 20%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_stale_go_auto_without_post_materializes_dry_run PASSED [ 22%]",".claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py::TestFreshGoSnapshots::test_stale_go_at_post_check_does_not_dedupe PASSED [ 25%]"],"stdout_truncated":true,"stdout_original_line_count":59,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":253,"fix_hint":null,"annotations":{"baseline_expect":"pass","vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":2,"raw":"# baseline-expect: pass"},"strict":null,"repair":null},{"ac":"AC8","line":3,"raw_command":"uv run --locked pytest .claude/skills/impl-review-loop/tests/test_ensure_contract_snapshot.py -k test_parser_result_with_canonical_body_sha256_is_consumed -v","command_hash":"sha256:b8a839eaa767d9380f5cb3440096e1fc47eec67ea30b5a10c6caedfdc91cff6f","runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_pr_review_only","decision":"go","scope_class":"pr_review_only","confidence":"low","stdout_head":[],"stdout_truncated":false,"stdout_original_line_count":1,"stderr_head":[],"stderr_truncated":false,"stderr_original_line_count":1,"runner_env_delta":{},"duration_ms":0,"fix_hint":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"pr-review-judge","deferred_reason":"VC marked pr_review_only; verification deferred to PR review","runtime_verification_required":false}]
      source: ensure_contract_snapshot_auto
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