Skip to content

実装: PR #1964 の battle-stage 寸法修正に伴い vrt-running-hud-overlay.png VRT baseline を更新する #1980

Closed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "none"
goal_ref: "PR #1964(#1956 実装)の .battle-stage responsive CSS 修正に伴い、Canvas mask で空洞化した running-hud-overlay-legacy-current VRT の capture semantics を修正し、HUD を実際に検証できる baseline へ更新する"
change_kind: code

Parent Issue

none

Parent Goal Ref

Current Validated Scope

  • tests/e2e/visual-utils.ts の expectDomOverlayScreenshot() は、running-hud-overlay-legacy-current を含む DOM overlay baseline すべてに対して Playwright mask: [page.locator('canvas')] を適用している(L346-354)。
  • .battle-ui-layer は .battle-stage__viewport に対する position: absolute; inset: 0(src/style.css L150-160)であり、PR feat(ui): move running combat HUD into a compact battle-stage overlay (#1375) #1925 以降 Canvas と overlay root がほぼ同一の bounding box を持つ。
  • 上記2点の組み合わせにより、vrt-running-hud-overlay.png の実質的な撮影内容は HUD([data-combat-hud])ではなく <canvas> mask(#FF00FF の単色矩形、面積比 99.8% 以上)である(PR feat: fixed logical arena の responsive Canvas presentation を分離する (#1956) #1964 の failing e2e artifact 解析で確認済み。full-page screenshot には HUD が正常描画されている一方、VRT actual には HUD が写っていない)。
  • 新しい実寸法 1230x693(__screenshots__ baseline PNG)に対して、この canvas mask 起因の空洞化 capture defect を修正しないまま candidate PNG を差し替えることはできない。既存の [data-visual-mask='true'] opt-in パターン(tests/e2e/visual.freeze.css)を capture 側の mask 方式に踏襲する。

Remaining Parent Gaps

なし。

Outcome

running-hud-overlay-legacy-current(vrt-running-hud-overlay.png)の capture が、Canvas 全体を覆う mask ではなく HUD を実際に検証できる状態に修正され、HUD(Hull / Kills / Elapsed / Weapon / Assist / Pause)の視覚回帰を検知できる baseline として再生成された状態。あわせて、この baseline が意図せず単色 mask 化した場合に screenshot test が確実に fail することを保証する negative control test が追加され、docs/dev/visual-baseline-registry.md の該当行が新しい capture policy と同期している。

In Scope

  • tests/e2e/visual-utils.ts の running-hud-overlay-legacy-current 用 capture 経路(expectDomOverlayScreenshot() またはこのシナリオ専用の引数/フラグ)を、Playwright mask オプションで canvas を隠す方式から、既存の tests/e2e/visual.freeze.css の [data-visual-mask='true'] opt-in パターンに倣った CSS visibility: hidden 相当の除外方式へ変更する。他の DOM overlay baseline(running-hud 等)の capture 方式には影響させない。
  • tests/e2e/visual-overlay.spec.ts の running-hud-overlay-legacy-current シナリオに、HUD([data-combat-hud])を意図的に非表示化または変形させた場合に screenshot 比較が確実に fail することを確認する negative control test を追加する。
  • candidate PNG が単一色(旧 mask 色相当)で埋め尽くされていないことを機械的に検証するチェックを追加する。新規 npm 依存は追加せず、既存の Playwright ブラウザコンテキスト(page.evaluate + <canvas> 2D getImageData)等、リポジトリに既にある手段で実装する。
  • 上記修正を反映したうえで tests/e2e/__screenshots__/visual-overlay.spec.ts/vrt-running-hud-overlay.png baseline を実際の DOM overlay 描画(Canvas 非表示状態、1230x693)で再生成する。expected/actual/diff を個別に目視確認したうえでコミットする。
  • docs/dev/visual-baseline-registry.md の running-hud-overlay-legacy-current 行(capture policy 列・comparator 列)を、mask 方式変更と新しい実寸法に合わせて更新する。

Out of Scope

  • capture root を [data-battle-ui-root] から [data-combat-hud] に切り替えること。既存の combat-hud-running (component VRT)(docs/dev/visual-baseline-registry.md 別行、Vitest Browser Mode、component-vrt-report 非-required job)を required gate 化する検討は別 Issue で扱う。
  • running-hud-paused / result-timeout / final-no-command-rail 等、pending-baseline 状態にある他シナリオへの対応。
  • HUD の配置・挙動そのものの変更(src/ui/combatHud.ts / src/ui/HudController.ts の機能変更)。
  • src/style.css の .battle-stage__viewport / .battle-ui-layer 自体の変更。Canvas 非表示化はテスト専用 CSS(tests/e2e/visual.freeze.css またはシナリオ専用 stylePath)で行い、production CSS は変更しない。
  • 新規 npm 依存(pngjs / sharp / pixelmatch 等)の追加。

Acceptance Criteria

  • AC1: tests/e2e/visual-utils.ts の running-hud-overlay-legacy-current 用 capture 経路が、新しい canvasVisibility オプション(既定 'mask' = 現行 Playwright mask 挙動、'hidden' = CSS visibility 除外)を持ち、tests/e2e/visual-overlay.spec.ts の running-hud-overlay-legacy-current 呼び出し箇所が canvasVisibility: 'hidden' を指定している。他の DOM overlay baseline の呼び出し箇所は既定値のまま変更していない
  • AC2: 再生成された vrt-running-hud-overlay.png について、単一色ピクセル比率が閾値未満(mask 化されていないこと)であることを機械的に検証する、タイトルに "pixel diversity" を含む test が追加され、そのテストが新しい baseline に対して PASS する
  • AC3: [data-combat-hud] を意図的に非表示化または変形させると tests/e2e/visual-overlay.spec.ts の running-hud-overlay-legacy-current screenshot assertion が確実に fail することを確認する、タイトルに "negative control" を含む test が追加され、実行して意図通り fail することを確認済みである
  • AC4: tests/e2e/visual-overlay.spec.ts の全シナリオ(既存の test.skip() 対象を除く)が PASS する
  • AC5: 本 PR の diff(origin/main との比較)が Allowed Paths 内のファイルのみに限定されている
  • AC6: docs/dev/visual-baseline-registry.md の running-hud-overlay-legacy-current 行に、新しい canvasVisibility capture policy への言及が追記されている

Verification Commands

# AC1
$ rg -n "canvasVisibility: 'hidden'" tests/e2e/visual-overlay.spec.ts
$ rg -n "canvasVisibility" tests/e2e/visual-utils.ts

# AC2
# preflight-scope: runtime_only
$ pnpm run test:vrt:update:e2e
# preflight-scope: runtime_only
$ pnpm exec playwright test tests/e2e/visual-overlay.spec.ts -g "pixel diversity"

# AC3
# preflight-scope: runtime_only
$ pnpm exec playwright test tests/e2e/visual-overlay.spec.ts -g "negative control"

# AC4
# preflight-scope: runtime_only
$ pnpm run test:vrt:e2e

# AC5
# baseline-expect: pass
$ git diff --name-only origin/main...HEAD

# AC6
$ rg -n "canvasVisibility" docs/dev/visual-baseline-registry.md

Runtime Verification Applicability

  • decision: immediate
  • reason: 本 Issue の Outcome は Playwright ブラウザプロセスを起動して実際に DOM overlay を描画・撮影し、baseline PNG との画素比較を行うことそのものであり、静的検証(typecheck/lint/unit test)だけでは AC2〜AC4 を検証できない。動作検証が本 Issue のスコープ内で完結する。
  • if immediate: AC2 / AC3 / AC4 に <!-- runtime-verification: true --> を付与済み。
    applicable_acs: AC2, AC3, AC4
    execution_environment: VITE_E2E_MODE=true pnpm build 済みの dist を LOOP_VRT_LANE=true で配信する Playwright(CI pinned container、または同等のローカル環境)。対応 VC は # preflight-scope: runtime_only を付与しており、issue-contract-review の静的 preflight sandbox では実行せず test-runner が実環境で実行する。
    skip_conditions: Playwright ブラウザ実行環境が利用不可(依存 browser binary 未インストール、CI runner 未起動、ネットワーク遮断等)の場合は SKIP(exit 77 / stdout SKIP: プレフィックス)を宣言し、Stop Condition として人間判断を仰ぐ。
    fallback_policy: SKIP は検証 PASS を意味しない。SKIP 発生時は該当 AC を未検証のまま Draft PR に明記し、実行可能な環境で再実行するまで merge しない。
    artifact_requirements: expected/actual/diff PNG、実行 exit code、head SHA、実行コマンドを PR に証跡として添付する。

Allowed Paths

  • tests/e2e/visual-overlay.spec.ts
  • tests/e2e/visual-utils.ts
  • tests/e2e/visual.freeze.css
  • tests/e2e/__screenshots__/visual-overlay.spec.ts/
  • docs/dev/visual-baseline-registry.md

Stop Conditions

  • Allowed Paths 外の変更が必要と判明した場合
  • In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
  • 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
  • 後続 Phase / 別スコープへの波及が判明した場合
  • nested SubAgent delegation が必要になった場合
  • 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
  • capture root を [data-combat-hud] に切り替える等、本 Issue が選択した capture 方式(CSS visibility 除外)自体を変更する必要が生じた場合(Issue 固有)
  • 新規 npm 依存の追加が必要と判明した場合(Issue 固有)

Required Skills

なし

Required Design References

  • tests/e2e/visual-utils.ts
  • tests/e2e/visual.freeze.css
  • docs/dev/visual-baseline-registry.md
  • playwright.config.ts
  • package.json(test:vrt / test:vrt:e2e / test:vrt:update:e2e スクリプト)

Scope Delta(任意)

N/A

Background / Notes for Reviewer

本 Issue は当初「vrt-running-hud-overlay.png を 900×507 から 1230×693 に差し替えるだけ」という契約だったが、OWNER レビュー(issuecomment-5172060362、REQUEST_CHANGES / P0 blocker)により、現行 VRT が HUD を実質的に検証できていない(capture が Canvas mask でほぼ全面覆われている)ことが判明したため、契約全体を再定義した。

原因: #1385 で DOM overlay 撮影時の Canvas 除外処理(mask)が導入され、#1386 / PR #1721 で [data-battle-ui-root] 全体を撮る primary VRT が追加された。その後 PR #1925(コミット 968af36e)が Canvas と .battle-ui-layer を同じ .battle-stage__viewport 内へ移し、両者をほぼ同一の bounding box にした。Playwright の mask は対象要素の bounding box を完全に塗りつぶすため、Canvas と overlay root が同寸法になった結果、その上に描画されている HUD も mask に覆われるようになった。

修正方針は、OWNER レビューが提示した二案((a) capture root を [data-combat-hud] に切替、(b) 全面 overlay の composition を残したまま Canvas を Playwright mask ではなく CSS visibility: hidden で非表示にする)のうち、(b) を採用する。理由:

  • 既存の tests/e2e/visual.freeze.css に [data-visual-mask='true'] という同種の opt-in visibility 除外パターンが既に存在し、実装パターンとして踏襲できる。
  • [data-combat-hud] を直接撮影する capture は既に combat-hud-running (component VRT)(docs/dev/visual-baseline-registry.md 内の別行、Vitest Browser Mode、component-vrt-report として non-required)として存在しており、これを Playwright E2E lane で重複実装せず、required gate 化するかどうかは別 Issue の判断とする。
  • capture root の切替は running-hud-overlay-legacy-current という baseline ID・registry entry の意味自体を変える大きな変更になり、本 Issue の Allowed Paths を大きく広げるため。

Refs #1956
Refs #1964
Refs #1925

Activity

  1. added
    phase/implementation
    agent/implementer
    enhancement
    on Aug 3, 2026
  2. squne121 commented on Aug 3, 2026

    @squne121
    OwnerAuthor

    判定

    REQUEST_CHANGES — P0 blocker。現状の #1980 は実装してはいけません。

    Issue は「vrt-running-hud-overlay.png を 900×507 から 1230×693 に差し替えるだけ」としていますが、現在の VRT は HUD を撮影できておらず、Canvas mask の矩形寸法だけを比較しています。PNG だけ更新すると CI は green になりますが、HUD の視覚回帰検知は実質ゼロのままです。

    関連変更の因果関係

    #1385 で DOM overlay 撮影時の Canvas 除外処理が導入され、#1386 / PR #1721 で [data-battle-ui-root] 全体を撮る primary VRT が追加されました。

    その後、PR #1925 が Canvas と .battle-ui-layer を同じ .battle-stage__viewport 内へ移し、両者を同一の containing block、ほぼ同一の矩形にしました。 現行コードでも .battle-ui-layer は Canvas viewport に対する position:absolute; inset:0 で、helper は overlay を撮影しながら canvas 全体を mask しています。

    Playwright の mask は対象要素の bounding box を完全なピンク色 #FF00FF で覆います。つまり Canvas と overlay root が同じ寸法なら、その上に存在する HUD も撮影結果上は mask に覆われます。(Playwright)

    P0: CI artifact が「空の視覚契約」である

    PR #1964 の failing e2e artifact を取得し、PNG を直接解析しました。

    画像 | 寸法 | #FF00FF 比率 | 実質的な内容 -- | -- | -- | -- expected baseline | 900×507 | 99.803% | Canvas mask CI actual | 1230×693 | 99.856% | Canvas mask retry actual | 1230×693 | actual と byte-identical | Canvas mask
    • CI actual

    • Expected baseline

    • Diff

    • 同じ失敗時の full-page screenshot

    • test-results 一式

    full-page screenshot には右上の HUD が正常に描画されています。一方、VRT の actual には HUD が一切なく、ほぼ全面が mask 色です。したがって今回検知されたのは、厳密には HUD レイアウトの変更ではなく mask 対象 Canvas の 900×507 → 1230×693 への拡大です。

    既存の敵対的テストも「masked screenshot と unmasked screenshot が異なる」ことしか確認しておらず、mask 後の画像に HUD が残っていることは検証していません。別テストで 14.4 s の DOM text は確認していますが、VRT 自体の感度を保証してはいません。

    P1: Verification Commands が baseline 更新手順として不正確

    #1980 は次の一般コマンドを指定しています。

    VITE_E2E_MODE=true pnpm build
    pnpm exec playwright test tests/e2e/visual-overlay.spec.ts
    

    しかしリポジトリには既に VRT 専用契約があります。

    • test:vrt: build と LOOP_VRT_LANE=true を設定

    • test:vrt:e2e: CI の build 済み dist 前提

    • test:vrt:update:e2e: --update-snapshots=all を明示した候補生成経路

    一般コマンドでは LOOP_VRT_LANE=true が付かず、ローカル環境では 4173 番ポート上の古い preview server を再利用する余地があります。また --update-snapshots がないため、既存 mismatch の baseline 更新コマンドにもなっていません。現行 config は CI では snapshot 更新を禁止し、ローカルの既定は missing snapshot のみです。 Playwright CLI でも snapshot 更新モードは明示的に選択する仕様です。(Playwright)

    さらに visual baseline は OS、ブラウザ、フォント、描画環境に依存するため、比較環境と同一環境で生成すべきです。(Playwright) このリポジトリの CI は Playwright 1.60.0 と digest 固定の Playwright container を使用しています。

    P1: Scope が自己矛盾している

    AC4 は「PR diff は PNG 一件だけ」と要求していますが、Allowed Paths には tests/e2e/visual-overlay.spec.ts 自体が含まれています。これでは locator、mask、tolerance、test.skip() を変更して test を弱めても Allowed Paths gate を通せます。

    逆に、今回必要な本質的修正は helper、VRT spec、registry のいずれかに触れるため、「コード変更は Out of Scope」「PNG のみ」という契約では解決不能です。Stop Condition に該当するため、現行契約のままなら実装ループは停止すべきです。

    P2: Acceptance Criteria が証拠になっていない

    現行 AC には次の問題があります。

    必須の契約改稿

    Issue の目的を、単純な baseline 更新から次へ変更すべきです。

    PR #1925 の viewport containment 変更により空洞化した DOM overlay VRT の capture semantics を修正し、HUD を実際に検証する baseline を再生成する。

    推奨実装は、[data-battle-ui-root] 全面ではなく [data-combat-hud] パネルを直接撮影し、この capture では Canvas mask を使用しないことです。HUD の配置、ラベル、chrome、折返しを直接比較でき、Canvas のランダム描画も混入しません。

    全面 overlay の composition を残す必要がある場合は、Playwright mask ではなく VRT 用 stylePath で Canvas を visibility: hidden にしてください。Playwright は screenshot 専用 CSS による要素非表示をサポートしています。(Playwright)

    改稿後の最低限の AC は次です。

    1. capture に Hull / Kills / Elapsed / Weapon / Assist / Pause が実際に含まれる。

    2. HUD を非表示または意図的に変形すると screenshot test が確実に fail する negative control がある。

    3. candidate PNG が全面 mask 色でないことを機械検証する。

    4. registry の capture root、mask policy、comparator、environment fingerprint を実装と同期する。

    5. pinned CI-equivalent container で expected / actual / diff を生成し、head SHA、artifact URL、digest、目視判断を記録する。

    6. --retries=0 の targeted VRT を複数回実行し、同一画像になることを確認する。

    7. merge-base origin/main HEAD に対する diff で変更ファイルを検査する。

    8. 最後に required e2e と ci-verdict-summary が green であることを確認する。

    最終判断

    #1980 の現行「PNG 一件だけ更新」方針は reject です。

    1230×693 の画像へ差し替える前に、HUD が mask に完全に隠れる capture defect を修正する必要があります。現状の baseline 更新は「正しい UI を承認する」のではなく、「大きくなったピンク矩形を正として固定する」変更です。

    # 判定

    REQUEST_CHANGES — P0 blocker。現状の #1980 は実装してはいけません。

    Issue は「vrt-running-hud-overlay.png を 900×507 から 1230×693 に差し替えるだけ」としていますが、現在の VRT は HUD を撮影できておらず、Canvas mask の矩形寸法だけを比較しています。PNG だけ更新すると CI は green になりますが、HUD の視覚回帰検知は実質ゼロのままです。

    関連変更の因果関係

    #1385 で DOM overlay 撮影時の Canvas 除外処理が導入され、#1386 / PR #1721 で [data-battle-ui-root] 全体を撮る primary VRT が追加されました。

    その後、PR #1925 が Canvas と .battle-ui-layer を同じ .battle-stage__viewport 内へ移し、両者を同一の containing block、ほぼ同一の矩形にしました。 現行コードでも .battle-ui-layer は Canvas viewport に対する position:absolute; inset:0 で、helper は overlay を撮影しながら canvas 全体を mask しています。

    Playwright の mask は対象要素の bounding box を完全なピンク色 #FF00FF で覆います。つまり Canvas と overlay root が同じ寸法なら、その上に存在する HUD も撮影結果上は mask に覆われます。([Playwright]1)

    P0: CI artifact が「空の視覚契約」である

    PR #1964 の failing e2e artifact を取得し、PNG を直接解析しました。

    画像 寸法 #FF00FF 比率 実質的な内容
    expected baseline 900×507 99.803% Canvas mask
    CI actual 1230×693 99.856% Canvas mask
    retry actual 1230×693 actual と byte-identical Canvas mask
    • CI actual
    • [Expected baseline](sandbox:/mnt/data/pr1964-test-results/visual-overlay-GIVEN-the-r-851d9-y-current-baseline-AC5-AC6--chromium/vrt-running-hud-overlay-expected.png)
    • [Diff](sandbox:/mnt/data/pr1964-test-results/visual-overlay-GIVEN-the-r-851d9-y-current-baseline-AC5-AC6--chromium/vrt-running-hud-overlay-diff.png)
    • [同じ失敗時の full-page screenshot](sandbox:/mnt/data/pr1964-test-results/visual-overlay-GIVEN-the-r-851d9-y-current-baseline-AC5-AC6--chromium/test-failed-1.png)
    • [test-results 一式](sandbox:/mnt/data/pr1964-test-results.zip)

    full-page screenshot には右上の HUD が正常に描画されています。一方、VRT の actual には HUD が一切なく、ほぼ全面が mask 色です。したがって今回検知されたのは、厳密には HUD レイアウトの変更ではなく mask 対象 Canvas の 900×507 → 1230×693 への拡大です。

    既存の敵対的テストも「masked screenshot と unmasked screenshot が異なる」ことしか確認しておらず、mask 後の画像に HUD が残っていることは検証していません。別テストで 14.4 s の DOM text は確認していますが、VRT 自体の感度を保証してはいません。

    P1: Verification Commands が baseline 更新手順として不正確

    #1980 は次の一般コマンドを指定しています。

    VITE_E2E_MODE=true pnpm build
    pnpm exec playwright test tests/e2e/visual-overlay.spec.ts

    しかしリポジトリには既に VRT 専用契約があります。

    • test:vrt: build と LOOP_VRT_LANE=true を設定
    • test:vrt:e2e: CI の build 済み dist 前提
    • test:vrt:update:e2e: --update-snapshots=all を明示した候補生成経路

    一般コマンドでは LOOP_VRT_LANE=true が付かず、ローカル環境では 4173 番ポート上の古い preview server を再利用する余地があります。また --update-snapshots がないため、既存 mismatch の baseline 更新コマンドにもなっていません。現行 config は CI では snapshot 更新を禁止し、ローカルの既定は missing snapshot のみです。 Playwright CLI でも snapshot 更新モードは明示的に選択する仕様です。(Playwright)

    さらに visual baseline は OS、ブラウザ、フォント、描画環境に依存するため、比較環境と同一環境で生成すべきです。([Playwright]3) このリポジトリの CI は Playwright 1.60.0 と digest 固定の Playwright container を使用しています。

    P1: Scope が自己矛盾している

    AC4 は「PR diff は PNG 一件だけ」と要求していますが、Allowed Paths には tests/e2e/visual-overlay.spec.ts 自体が含まれています。これでは locator、mask、tolerance、test.skip() を変更して test を弱めても Allowed Paths gate を通せます。

    逆に、今回必要な本質的修正は helper、VRT spec、registry のいずれかに触れるため、「コード変更は Out of Scope」「PNG のみ」という契約では解決不能です。Stop Condition に該当するため、現行契約のままなら実装ループは停止すべきです。

    P2: Acceptance Criteria が証拠になっていない

    現行 AC には次の問題があります。

    必須の契約改稿

    Issue の目的を、単純な baseline 更新から次へ変更すべきです。

    PR #1925 の viewport containment 変更により空洞化した DOM overlay VRT の capture semantics を修正し、HUD を実際に検証する baseline を再生成する。

    推奨実装は、[data-battle-ui-root] 全面ではなく [data-combat-hud] パネルを直接撮影し、この capture では Canvas mask を使用しないことです。HUD の配置、ラベル、chrome、折返しを直接比較でき、Canvas のランダム描画も混入しません。

    全面 overlay の composition を残す必要がある場合は、Playwright mask ではなく VRT 用 stylePath で Canvas を visibility: hidden にしてください。Playwright は screenshot 専用 CSS による要素非表示をサポートしています。(Playwright)

    改稿後の最低限の AC は次です。

    1. capture に Hull / Kills / Elapsed / Weapon / Assist / Pause が実際に含まれる。
    2. HUD を非表示または意図的に変形すると screenshot test が確実に fail する negative control がある。
    3. candidate PNG が全面 mask 色でないことを機械検証する。
    4. registry の capture root、mask policy、comparator、environment fingerprint を実装と同期する。
    5. pinned CI-equivalent container で expected / actual / diff を生成し、head SHA、artifact URL、digest、目視判断を記録する。
    6. --retries=0 の targeted VRT を複数回実行し、同一画像になることを確認する。
    7. merge-base origin/main HEAD に対する diff で変更ファイルを検査する。
    8. 最後に required e2e と ci-verdict-summary が green であることを確認する。

    最終判断

    #1980 の現行「PNG 一件だけ更新」方針は reject です。

    1230×693 の画像へ差し替える前に、HUD が mask に完全に隠れる capture defect を修正する必要があります。現状の baseline 更新は「正しい UI を承認する」のではなく、「大きくなったピンク矩形を正として固定する」変更です。

  3. squne121 commented on Aug 3, 2026

    @squne121
    OwnerAuthor

    Contract Review Result

    CONTRACT_REVIEW_RESULT_V1:
      status: go
      generated_at: "2026-08-03T22:18:11Z"
      generated_by: issue-contract-review
      issue_url: https://github.com/squne121/loop-protocol/issues/1980
      body_sha256: "sha256:1346b7b267b9c38e78b71fd83438a7c7f2aa2e8231ddf2c5c5dbf60ad97fcddb"
      checks:
        readiness: go
        blockers: pass
        product_spec: pass
        product_spec_check: {"schema":"product_spec_check/v1","applicability":"applicable","decision":"pass","triggers":{"docs_product_allowed_paths":false,"tasks_md_mentioned":false,"specify_artifact_mentioned":false,"generated_task_mentioned":false,"product_spec_context_present":false,"machine_readable_contract_present":true},"conditions":{"docs_product_requires_spec_evidence":{"status":"pass","evidence":[]},"tasks_md_not_direct_source":{"status":"pass","evidence":[]},"specify_not_canonical":{"status":"pass","evidence":[]},"diff_first_rationale_present":{"status":"pass","evidence":[]},"generated_task_trace_present":{"status":"pass","evidence":[]},"task_dependencies_materialized":{"status":"pass","evidence":[]}},"blocked_reasons":[],"body_sha256":"sha256:1346b7b267b9c38e78b71fd83438a7c7f2aa2e8231ddf2c5c5dbf60ad97fcddb","source_provenance":{"source_type":"body_file","body_file":"/tmp/contract_review_once_body_034v6shr.md"}}
        vc_preflight:
          decision: pass
          classifications: [{"ac":"AC1","line":2,"raw_command":"rg -n \"canvasVisibility: 'hidden'\" tests/e2e/visual-overlay.spec.ts","command_hash":"sha256:9f6d02f2d689497f99bacd752f6b23012b3e47f2e2e7d677a5ec9318312a68d5","execution_key_hash":"sha256:7075aea0b4d7e58164b277cf3d31211b10a778c428bdc6a5f7a2bdc9c8a02481","runner":"exec","exit_code":1,"classification":"expected_fail","category":"expected_baseline_fail","decision":"go","scope_class":"baseline_fail_expected","confidence":"high","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":2,"fix_hint":null,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null},{"ac":"AC1","line":3,"raw_command":"rg -n \"canvasVisibility\" tests/e2e/visual-utils.ts","command_hash":"sha256:a3fd0d4669983b08cd930c5bb8f24e6e3f4f59e59276aa0b0a6d2e3d04e8554a","execution_key_hash":"sha256:b0476e272cadd5c4c20d33ffa83ba7fdaf6cbbb5f7a22c3cc331dd655803d3b9","runner":"exec","exit_code":1,"classification":"expected_fail","category":"expected_baseline_fail","decision":"go","scope_class":"baseline_fail_expected","confidence":"high","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":1,"fix_hint":null,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null},{"ac":"AC2","line":7,"raw_command":"pnpm run test:vrt:update:e2e","command_hash":"sha256:991d1added8aa76d166f39b74f7398f8062dfd42bcc2fbc3777f7819e0456345","execution_key_hash":null,"runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_runtime_only","decision":"go","scope_class":"runtime_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,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"impl-review-loop","deferred_reason":"VC marked runtime_only; verification deferred to post-implementation runtime","runtime_verification_required":true},{"ac":"AC2","line":9,"raw_command":"pnpm exec playwright test tests/e2e/visual-overlay.spec.ts -g \"pixel diversity\"","command_hash":"sha256:280bd1302e3bf73638d21c7f5b2f1cda696c65082c91821f77404b7f23a1061b","execution_key_hash":null,"runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_runtime_only","decision":"go","scope_class":"runtime_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,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"impl-review-loop","deferred_reason":"VC marked runtime_only; verification deferred to post-implementation runtime","runtime_verification_required":true},{"ac":"AC3","line":13,"raw_command":"pnpm exec playwright test tests/e2e/visual-overlay.spec.ts -g \"negative control\"","command_hash":"sha256:6493de793374e34229d967f76d49fe3961ab041a37a6426efd00d609c7154856","execution_key_hash":null,"runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_runtime_only","decision":"go","scope_class":"runtime_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,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"impl-review-loop","deferred_reason":"VC marked runtime_only; verification deferred to post-implementation runtime","runtime_verification_required":true},{"ac":"AC4","line":17,"raw_command":"pnpm run test:vrt:e2e","command_hash":"sha256:b9f5ee1322429829a8535de5c8b631fd0cc33113b19eeef774007ea41e3a0583","execution_key_hash":null,"runner":"skipped","exit_code":null,"classification":"skipped","category":"preflight_scope_runtime_only","decision":"go","scope_class":"runtime_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,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null,"verification_owner":"impl-review-loop","deferred_reason":"VC marked runtime_only; verification deferred to post-implementation runtime","runtime_verification_required":true},{"ac":"AC5","line":21,"raw_command":"git diff --name-only origin/main...HEAD","command_hash":"sha256:be1f50637e3de31fde596ef434633a945474a3b9ee1b9961d2044b35c91f8f02","execution_key_hash":"sha256:670343b3424fcf9779479abd465ad3b7810269dde9cc87eb8f92ad66603386cf","runner":"exec","exit_code":0,"classification":"expected_pass","category":"baseline_expect_pass","decision":"go","scope_class":"regression_gate","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":1,"fix_hint":null,"certified_target_paths":null,"annotations":{"baseline_expect":"pass","vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":20,"raw":"# baseline-expect: pass"},"strict":null,"repair":null},{"ac":"AC6","line":24,"raw_command":"rg -n \"canvasVisibility\" docs/dev/visual-baseline-registry.md","command_hash":"sha256:bb2542fb3af7c49850103899e2cc29eaf53de524d3c5c95f07c6e6d6a1100a80","execution_key_hash":"sha256:a25ff7ff5380d0136d7f6b6bc67b8a6269c2a75ce8033672c04ad07250bf6fe2","runner":"exec","exit_code":1,"classification":"expected_fail","category":"expected_baseline_fail","decision":"go","scope_class":"baseline_fail_expected","confidence":"high","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":1,"fix_hint":null,"certified_target_paths":null,"annotations":{"baseline_expect":null,"vc_role":null,"missing_baseline_expect":false},"annotation_source":{"line":null,"raw":null},"strict":null,"repair":null}]
        declared_path_overlap: {"schema":"declared_path_overlap/v1","advisory":true,"blocking":false,"decision":"advisory_only","disjoint":true,"overlapping_prs":[],"inventory":{"schema":"OPEN_PR_INVENTORY_V1","repo":"squne121/loop-protocol","state":"open","base_ref":"main","base_sha":"e8da0bb61af5646af3bcb53b3cad26f3314fb1a2","draft_policy":"include_drafts","prs":[{"number":1528,"title":"feat(cleanup): 同一実行内の branch-only fallback を追加","base_ref_name":"main","head_ref_name":"worktree-issue-1403-post-merge-cleanup-dedicated-branch-forc","head_ref_oid":"b29007580ae225eb9676c7f32c878ee2bb9ccaa9","is_draft":false,"is_cross_repository":false,"head_repository_owner":"squne121","head_repository_name":"loop-protocol","url":"https://github.com/squne121/loop-protocol/pull/1528","changed_files_count_graphql":4},{"number":1984,"title":"feat(ui): result screen と pause overlay を battle-stage 内に統合する","base_ref_name":"main","head_ref_name":"worktree-issue-1376-result-screen-pause-overlay-battle-stage","head_ref_oid":"4f9281e51ed73a14fc611c995cc03e7e8dd96d4b","is_draft":true,"is_cross_repository":false,"head_repository_owner":"squne121","head_repository_name":"loop-protocol","url":"https://github.com/squne121/loop-protocol/pull/1984","changed_files_count_graphql":8}],"fetched_count":2,"totalCount":2,"has_next_page":false,"complete":true,"saturated":false,"limit":200,"page_count":1,"inventory_digest":"sha256:ea1384ce91a12dc66de362fdc66146b78d8e8d2d1835d369569583dfa42985c9","errors":[]},"inventory_digest_extended":"sha256:05616e00c0cfd4018a7baeb9030ac65bc528a43088f00b36bc981dfc82cf86c7","errors":[],"note":"changed-file 名の単純な重なりのみを証明する advisory check。3-way merge・hunk 競合・rename/delete 競合は評価しない(実 Git merge 競合の判定は Issue #1792 の PAIRWISE_MERGE_OBSERVATION_V1 producer の責務)。単独では blocking にしない。disjoint は tri-state(true/false/null)— 観測が不完全な場合は null。"}
      source: ensure_contract_snapshot_auto
      expected_contract_fingerprint: {"issue_number":1980,"contract_source_kind":"issue_comment","contract_source_id":"5172344896","contract_body_sha256":"sha256:1346b7b267b9c38e78b71fd83438a7c7f2aa2e8231ddf2c5c5dbf60ad97fcddb","allowed_paths_normalized_sha256":"2b6c1708d6d42b9ce9ac21774771c8ce5df8373610d991141e8e7346f3e1c61c","base_ref":"main","base_sha_at_snapshot":"e8da0bb61af5646af3bcb53b3cad26f3314fb1a2"}
  4. squne121 commented on Aug 3, 2026

    @squne121
    OwnerAuthor

    issue-refinement-loop 終了報告

    termination_reason: approved

    OWNER の REQUEST_CHANGES コメント(issuecomment-5172060362、P0 blocker: 現行 VRT が Canvas mask で HUD を実質検証できていない)を受け、Issue #1980 の契約全体を書き直しました(PNG 差し替えのみ → capture semantics 修正 + negative control + pixel diversity 検証 + Runtime Verification Applicability 追加)。

    LOOP_HANDOFF_RESULT_V1:
      status: impl_ready
      routing_action: run_impl_review_loop
      contract_review:
        status: go
        gate_result: fresh_go
        latest_comment_url: "https://github.com/squne121/loop-protocol/issues/1980#issuecomment-5172344896"
        generated_at: "2026-08-03T22:18:47Z"
        body_sha256: "sha256:1346b7b267b9c38e78b71fd83438a7c7f2aa2e8231ddf2c5c5dbf60ad97fcddb"
      metadata:
        title_prefix_ready: true
        phase_label_ready: true
      auto_fixes:
        result: auto_fixed
        required:
          - kind: contract_snapshot_materialization
            executor: implementation-worker
            result: applied
            evidence:
              before: "go_comment_url: null"
              after: "contract_snapshot_url: https://github.com/squne121/loop-protocol/issues/1980#issuecomment-5172344896"
              comment_url: "https://github.com/squne121/loop-protocol/issues/1980#issuecomment-5172344896"
        skipped: []
      blockers: []
      permissions:
        unavailable: []
      generated_at: "2026-08-03T22:18:47Z"
      checked_body_sha256: "sha256:1346b7b267b9c38e78b71fd83438a7c7f2aa2e8231ddf2c5c5dbf60ad97fcddb"
      checker_exit_code: 0
      missing_sections: []
      missing_contract_keys: []
    FOLLOW_UP_MATERIALIZATION_RESULT_V1:
      schema_version: 1
      materialized_by: issue-refinement-loop
      follow_up_issues: []
      note_only_observations:
        - "`combat-hud-running (component VRT)`(docs/dev/visual-baseline-registry.md 記載、Vitest Browser Mode、component-vrt-report 非-required)を required gate 化するかどうかは、本 Issue の Out of Scope として明示的に別 Issue 判断に委ねた(起票はしていない)。"

    次のアクション: impl-review-loop へ Issue #1980 を渡して実装フェーズへ進めてください。

  5. squne121 commented on Aug 4, 2026

    @squne121
    OwnerAuthor

    implement-issue: 実装完了

    • PR: fix(e2e): capture HUD instead of canvas mask in running-hud-overlay-legacy-current VRT (#1980) #1988
    • Worktree: .claude/worktrees/issue-1980-vrt-canvas-hidden-hud
    • Branch: worktree-issue-1980-vrt-canvas-hidden-hud
    • Verification: typecheck/lint/test/build 4/4 PASS。gemini routing pytest 21 PASS。AC1(rg静的検証)/AC2(pixel diversity, 実行PASS)/AC3(negative control, 実行PASS)/AC4(全シナリオ, 4 passed 3 skipped)/AC5(Allowed Paths内5ファイルのみ)/AC6(registry更新) すべて確認済み。SKIP なし。
    • 後続: PR レビュー(pr-review-judge)→ マージ → post-merge-cleanup
  6. squne121 commented on Aug 4, 2026

    @squne121
    OwnerAuthor

    PR #1989 が本 Issue 待ちでスタック中

    Issue #1987「M4 E2E write-set audit helper (createAuditedContext) を共有モジュールへ抽出する」の実装 PR #1989 が、本 Issue で追跡中の tests/e2e/visual-overlay.spec.ts(vrt-running-hud-overlay.png)VRT baseline 不一致によりブロックされています。

    経緯

    次のアクション

    本 Issue(#1980)の VRT baseline 更新がマージされ、PR #1989 の同一 head で CI を再実行できれば、preview-namespace lane の green を確認して Issue #1987 の deferred verification 条件を満たせます。優先度を上げていただけると PR #1989 の merge-ready 判定を進められます。

    Related: Issue #1987 (#1987), PR #1989 (#1989)

  7. squne121 commented on Aug 4, 2026

    @squne121
    OwnerAuthor

    implement-issue: fix_delta 対応完了 (2026-08-04T11:52:00Z)

    OWNER の PR #1988 REQUEST_CHANGES レビュー(issuecomment-5178434876)で指摘された P1 blocker 2 件に対応した。

    • [P1] negative control を本番 matcher に復元: tests/e2e/visual-overlay.spec.ts の negative control を本来の expectDomOverlayScreenshot() / .rejects.toThrow() 呼び出しに戻し、testInfo.config.updateSnapshots === 'all' のとき test.skip() するガードを追加した(iteration-0 の baseline 破壊事故の再発防止)。
    • [P1] fail-closed guard 追加: tests/e2e/visual-utils.ts の expectDomOverlayScreenshot() に、canvasVisibility が既定 'mask' のまま canvas が capture root の 90% 超を覆う場合に throw する geometric guard を追加。
    • [P2] PR 本文同期: head SHA・AC3 証跡・skip 理由・並行 draft PR feat(ui): result screen と pause overlay を battle-stage 内に統合する #1984 との依存順序 Notes を更新。

    検証: CI pinned Playwright container(mcr.microsoft.com/playwright@sha256:9bd26ad900bb5e0f4dee75839e957a89ae89c2b7ab1e76050e559790e946b948)内で AC1-AC6 全て実行・PASS。baseline PNG は capture logic 未変更のため byte-identical。

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