Skip to content

fix: PR watch under load (skipped checks, stale head, repeated block, merge suggestion) - #62

Merged
lx-0 merged 3 commits into
mainfrom
fix/pr-watch-under-load
Nov 14, 2026
Merged

lx-0 merged 3 commits into
mainfrom
fix/pr-watch-under-load

Conversation

@lx-0

@lx-0 lx-0 commented Nov 14, 2026

Copy link
Copy Markdown
Member

Fixes the four main points of #61 (PR watch under load: 8 to 12 open PRs, 20 background agents).

  1. Skipped checks. A skipped or neutral check run that is neither required (branch rules, label) nor a review bot's check no longer makes a PR action_required. Required and review-bot checks still have to pass (a skipped required check still blocks, as before). optional_skipped_checks is no longer needed.
  2. Stale head. A git push the PostToolUse hook sees in a bound worktree sets pushed_at on that branch's watch (new columns branch, pushed_at, migrated in place). The line then reads head moved by a push ... ago, not yet polled instead of the old head's findings, and due() reads the PR on the next tick.
  3. Repeated block. Claude's UserPromptSubmit block is injected only when a line changed (ages excluded; fingerprint in meta per session) or a notice is pending. SessionStart (start, resume, compaction) resets it.
  4. review-lessons on every merge. The merge notice comes only when the watch saw at least one bot finding on the PR (a bot-thread: outbox row). ytstack-upkeep still lists every unchecked merged PR.

Not in this PR (planning with the rest of #54): the "plugin updated since this session started, reload skills" notice and one-step coordinator rotation.

Verification: tests/pr_watch/test_under_load.py (8 new), two existing tests adapted to the new behaviour (unchanged block not repeated; merge notice needs a seen bot finding); pr_watch 75 OK on Python 3.9 and 3.13, tests/pr-watch.test.sh 60 passed, tests/run-all.sh ALL SUITES PASSED, bin/ytstack-check OK, spec lint clean.

🤖 Generated with Claude Code

lx-0 and others added 3 commits November 14, 2026 22:44
… (issue #61)

Change-class workflows skip most jobs on purpose; a skipped job read as
action_required on every PR. Required checks and review-bot checks still
have to pass. optional_skipped_checks is no longer needed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…y on change, review-lessons only after a bot finding (issue #61)

- a git push in a bound worktree marks the branch's watch (pushed_at): the
  line says head moved instead of the old head's findings, and the worker
  reads the PR on its next tick
- Claude's UserPromptSubmit block is injected only when a line changed
  (fingerprint per session, reset on SessionStart) or a notice is pending
- the merge notice comes only when the watch saw a bot finding on the PR

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…-and-state, CHANGELOG)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-14T22:01:31.680507Z
We couldn’t complete this review. Comment @codex review to try again.
d39267c Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3c13b36338

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread tools/pr-watch/prwatch/hooks.py Resolved
Comment thread tools/pr-watch/prwatch/worker.py Resolved
@lx-0
lx-0 merged commit d39267c into main Nov 14, 2026
4 checks passed
@lx-0
lx-0 deleted the fix/pr-watch-under-load branch November 14, 2026 22:00
@lx-0

lx-0 commented Nov 14, 2026

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

lx-0 added a commit that referenced this pull request Nov 14, 2026
…nding count) (#64)

* fix: PR watch marks a head moved only when the remote-tracking ref differs; count bot findings by repo column (PR #62 review)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs: head moved needs a changed remote-tracking ref (pr-watch, spec hooks-and-state)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore: spec area checks-and-evals names test_under_load.py

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix: PR watch reads the local branch head when a push leaves no remote-tracking ref (PR #64 review)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore: spec area checks-and-evals notes the remote_head test

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant