Repository navigation
feat(autopilot): merge an all-ok release check epic to develop from the monitor (#2544) - #2545
Merged
Merged
Conversation
…he monitor When the latest release check result is all OK (marker allOk=1 with the PR and the topic head SHA), the monitor's main button becomes "develop へマージする". POST /release-check/merge re-reads the tracker and the PR, checks CI, conflicts, the head SHA, unhandled PR feedback, protected paths and the merge window, then marks the PR ready, merges it and closes the EPIC. A human merge on GitHub ends the EPIC the same way (applyReleaseMergedEpics). Closes #2544 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
🤖 autopilot status
Linked issue #2544. Maintained by autopilot (single writer); do not edit. |
gh pr view --json files stops at 100 files, so a large topic PR could skip the mesh and protected path checks. Read the files with paginated REST and refuse when the list is shorter than changedFiles. Add the fallback from #2544 item 6: when the topic -> develop PR is merged but the EPIC is still open outside Release Check, the monitor shows "close the EPIC" with the open sub-issues (they are kept open). POST /release-check/close checks the PR again and closes the EPIC. finishEpicMerge closes the issue before moving the project so a failed close does not leave an open issue in a terminal status. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
|
🤖 敵対的レビュー(round 1): 指摘 6 件(Must 2 / Question 2 / FYI 2) Must
Question
FYI
直してほしい指摘は、モニターの「AI に直してもらう」で指示を書くか、Request changes で ID を指定してから |
Author
|
人間の方針(2026-11-28): autopilot の直しは AI の判断で入れ、人間が実際に触って評価する。問題があればあらためて Issue にする。 Q2 は AI のおすすめ(いまの形)を採った: 「develop へマージする」は出したままにし、PR に未対応のレビューがあれば押したときに 409 |
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
リリース確認が全部 OK になった EPIC を、モニターの「あなた宛て」から develop へマージできるようにする。
人間が GitHub で topic → develop の PR をマージしたときも、daemon が同じ形で EPIC を閉じる。
Closes #2544
変えたこと
release-check.js):releaseResultMarker(round, {allOk, pr, head})で<!-- autopilot-release-result round=N allOk=1 pr=P head=SHA -->を書く。parseReleaseResultMarker/releaseCheckRoundsを追加。RESULT_REは属性が付いても round を読む(releaseCheckModeは今までどおり動く)。src/release-merge.js):releaseMergeReadiness: いちばん新しい round の結果が全部 OK で SHA があり、そのあとに新しい観点・結果・PR の未対応のレビューやコメントが無いかplanReleaseMerge: refuse / confirm / merge を決める。CI・コンフリクト・head の SHA・PR の状態・Bot の権限外のパス・メッシュ・時間で判断するselectMergedReleaseEpics/epicTopicBranch/releaseMergeCandidatehuman-action.jsのdevelopMergeWindow。モニターにも埋め込む): 日本時間で、平日 12:50〜13:15 と土日は時間内。それ以外(16:15 以降の予備の時間も)は時間外。act: merge-epic)にする。時間外のときは確かめの文にPOST /release-check/merge?issue=N(release-check-http.jsのreleaseMergeOnce): 押したときだけ、トラッカー・PR のレビューとコメント・sub-issue の本文・PR を読み直して確かめる。そのあと Bot で draft を外し、--mergeでマージしてfinishEpicMergeを走らせる(Status=Close、AI Status を空、🙋 を外す、Issue を閉じる)。二重押しと worker の実行中は 409。マージの失敗はsanitizeForSurfaceを通して 502 で返し、GitHub でのマージを頼む。applyReleaseMergedEpics)。見つかれば同じfinishEpicMergeを走らせる。allOk/pr/headSha)から覚え、release-check-merges.jsonに保存する。再起動後も残る。autopilot-release-check.md): 全部 OK のときの目印と結果の項目、文言「モニターの『develop へマージする』か GitHub で人間が行う」。README.md(リリース確認の節、HTTP の表)、state-machine.md#16c の出口、autonomous-contract.mdの結果の項目。phaseForItemは変えていないので、state-machine のテストは変えていない。AI が決めたこと
confirmOffHours: trueを送る。ほかから叩いて付けなければ 409off-hours+confirm: true。MESH_PATH_PATTERNS)を含むときは、平日 8:00〜19:00 は確かめても断る。pr-feedback)で断る。no-headで断り、GitHub でのマージを頼む。スクリーンショット(
tools/autopilot/bin/pw-check、/board を差し替えた headless)全部 OK の EPIC の行と確かめ:
時間外の確かめ(平日 10:00 に固定):
テスト
test/release-merge.test.js(12 件):releaseMergeOnce(順番・断る・二重押し・Bot で通らない)node --testで release-merge / release-check / release-check-http / human-action / monitor / project / state-machine / daemon / release-page / contract(341 件、すべて通過)。bin/lint-changedok。注意
マージしたあと、daemon を再起動するまで効かない。
🤖 Generated with Claude Code