Repository navigation
Revert "fix(#324): refresh session-recording-policy table + warning per PR #355 review" - #358
Conversation
|
● 完了。状況をまとめます: Recovery summary
マージ手順(人間判断)
インシデント要約
✻ Worked for 6m 28s |
結論PR #358 は merge 可。ただし「復旧 PR」としてのみ承認です。実装価値は「 ただし、PR #358 は単体で品質改善ではありません。#358 を merge しただけでは、main は 敵対的レビューBlocker 1: #358 は #355 より後に merge された瞬間に破壊的になる#358 の diff は 修正要求: PR #358 本文の冒頭に以下を追加してください。 ## Merge invariant
This PR is valid only while main HEAD contains abbc61a and PR #355 has not been merged.
- MUST merge this PR before PR #355.
- If PR #355 is merged first, close this PR without merging.
- Before merge, verify:
- main HEAD or merge base still includes abbc61a as the accidental direct-push commit
- `git diff --exit-code 032c91b6b173ec2430738b8ab1cee54c159ae45c ab2099896c790fec5345437af5e751c79cf6d265 -- docs/dev/session-recording-policy.md`Blocker 2: 「復旧完了」と「再発防止完了」が混ざっている#358 は main の tree 復旧だけを扱う PR です。一方で、事故原因は branch protection / push gate / SubAgent 権限境界の欠落です。PR 本文は follow-up 候補を列挙していますが、Issue 化を復旧完了条件にしていません。これは危険です。今回の main direct push は、GitHub 側の保護がない、または管理者・権限持ち actor が bypass できる状態だったことを示しています。GitHub の protected branch は PR review、status checks、会話解決、push 制限、bypass 禁止などを設定できますが、管理者や bypass 権限者には既定で制限が適用されないため、必要なら “Do not allow bypassing” も有効化する必要があります。([GitHub Docs]2) 修正要求: #358 merge 前後のどちらでもよいですが、最低限次の follow-up Issue を作り、#358 本文にリンクしてください。
Blocker 3:
|
Reviewer 指摘への対応報告 (#issuecomment-4527776240)Blocker 1: Merge invariant の明記 → 対応済みPR 本文冒頭に Blocker 2: 再発防止 follow-up Issue 起票 → 対応済み
PR 本文の Blocker 3: push guard 設計強化 → #360 で反映済み
非 blocker への対応
Merge invariant セクションに以下を含めた:
Merge invariant に「PR #355 が未 merge であることを事前確認」を明記。 最終確認verdict_response: APPLIED_ALL_BLOCKERS
recovery_status:
- "#358 ready: merge invariant + follow-up links"
- "#355 head: e2b1aaa (Draft, mergeStateStatus: CLEAN)"
- "#359 + #360 created for recurrence prevention"
merge_order: ["#358", "#355"]
incident_closure_conditions:
- "#358 merged"
- "#355 merged"
- "#359 implemented and merged"
- "#360 implemented and merged" |
* docs(#359): record main branch protection / ruleset hardening main 直接 push を GitHub remote 側で拒否する保護設定を ruleset 一次・branch protection 二次の多層構成で導入し、設定 snapshot と検証手順を docs/ops/branch-protection.md に記録する。 - Ruleset `main-direct-push-protection` (id 16796903) を active で作成(bypass_actors: []) - Branch protection に `python-test` を追加し `enforce_admins: true` に更新 - `git push origin HEAD:main` が `GH013` で remote rejected されることを実測 Closes #359 Refs #358 #355 #360 Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]> * docs(#359): address PR #362 review blockers — add raw snapshots + source pinning + Stop Condition Blocker 対応: - Blocker 1: ruleset / branch protection の raw JSON snapshot を fenced code block で追加(監査正本) - Blocker 2: `bypass_pull_request_allowances` 取得結果(field_absent / 個人 repo 構造上不在)を明示 - Blocker 3: `required_status_checks.checks[].app_id: 15368` で GitHub Actions に source 固定済みであることを明記 - Blocker 4: AC6 検証コマンドに `HEAD:main` 契約準拠形式 (A form) を追加、既存 commit-tree 形式は B form として併記、想定外 push 成功時の Stop Condition を追記 - Blocker 5: `required_approving_review_count: 0` を意図的選択として明示、承認件数引き上げは別 Issue 対象であることを記録 AC マッピング表も raw snapshot / bypass field / source pinning の根拠を反映して更新。 Refs #359 #362 Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 4.7 (1M context) <[email protected]>
Merge invariant
This PR is valid only while main HEAD contains
abbc61aand PR #355 has not been merged.gh api repos/squne121/loop-protocol/commits/main --jq .shaで main HEAD がabbc61aを含むことgit diff --exit-code 032c91b6b173ec2430738b8ab1cee54c159ae45c ab2099896c790fec5345437af5e751c79cf6d265 -- docs/dev/session-recording-policy.md(tree-equivalence: revert 後 main の該当ファイルが 032c91b と一致することの事前確認)Summary
abbc61aを main から revert します。本 commit は impl-review-loop の iter1 fix として PR #355 branch へ push される予定だった ものが、誤って main へ直接 push されたインシデント commit です。Background
git pushを実行した際、worktree の状態確認不足で main を直接更新Recovery plan
032c91bに戻すe2b1aaa, cherry-pick) として main に戻るVerification
032c91b) と同一 treeFollow-up Issues(再発防止)
本 PR は復旧 PR としてのみ承認。再発防止は別 Issue で扱う:
git push origin HEAD:main系を exit 2 で block)復旧 (#358 merge + #355 merge) と再発防止 (#359, #360) は分けて扱い、両者が完了するまで incident は close しない。
🤖 Generated with Claude Code