v0.5.0
Watcher: keep watching past green with PR_SENTINEL_WATCH_UNTIL=closed
The watcher exits on ready, but the PR is still open at that point and sitting in human merge review — exactly the window where a sibling PR merging turns it CONFLICTING. Nothing is left watching, so nothing wakes you. This only bites with concurrent PRs, so it's an opt-in stopping condition rather than a change to the default.
Set PR_SENTINEL_WATCH_UNTIL=closed and the watcher reports green once as a non-terminal ready_watching notice and keeps polling. The DIRTY/BEHIND checks already at the top of the loop still fire, so a later conflict, a branch falling behind, or a newly failing check wakes the session; the watch ends when the PR is merged or closed.
Exiting on a still-green PR and relying on a relaunch does not work: the relaunched watcher re-evaluates immediately, sees the same green state, and exits again with no sleep in the cycle — a spin loop, not a watch.
Trade-offs
- The session is not woken when the PR turns green, so it can't announce "ready for review" the moment it happens — the notice lands in the watcher's task output instead.
- A watch that now spans human review time usually wants a larger
PR_SENTINEL_TIMEOUTthan the 1-hour default, or it wakes with atimeoutevent and needs a relaunch.
Stop hook
ready_watching is a distinct event name so the Stop hook can tell "handed off" from "green, still watching". A watch in closed mode that exits on the notice without a terminal event now blocks once to relaunch, instead of going quiet on a PR that is still open and unwatched.
Trust boundary unchanged
No new data source: the loop already read mergeStateStatus every cycle. There is still no merge, no comment ingestion, and no fix outside the visible session.
Closes #23.
Full changelog: v0.4.1...v0.5.0