Repository navigation
fix(server): PR watches without a host event feed notice check changes within seconds #37494
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -326,7 +326,8 @@ when requested. Settling a thread refreshes its open and closed reviews once; af | |
| review is terminal. An open or unsynced link keeps it active. | ||
|
|
||
| Ask the agent to watch, monitor, or babysit a pull request and it calls `watch_pull_request`. While | ||
| the thread is active, the server checks the pull request every two minutes and wakes the agent when a | ||
| the thread is active, the server checks the pull request every two minutes, and every 20 seconds while its | ||
| checks are running, and wakes the agent when a | ||
|
Comment on lines
+329
to
+330
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Limit the 20-second timing claim to eligible hosts. If a host has no fingerprint support, running checks still rely on the two-minute sweep. A live feed also disables this probe. State that the server probes every 20 seconds when checks run, no live feed is available, and the host supports fingerprints. Keep the two-minute fallback explicit.
|
||
| check fails or waits for a maintainer's approval, the required checks pass, someone else comments or reviews, or the branch starts to | ||
| conflict. On github.com it also wakes the agent, with GitHub's reason, when the merge queue drops | ||
| the pull request without merging it. Threads in a project that watch the same pull request share one check. On GitHub, a check | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Read each changed PR as its fingerprint returns.
The probe waits for every due
watchFingerprintcall to finish before it reads any changed PR at line 893. A slow fingerprint on host B therefore delays the read of host A's already-changed PR for the full duration of B's call.fingerprintOfsets no timeout, so the bound depends on the provider call.If a call never returns, the
foreverprobe loop stalls, and no later probe runs for any PR until the call returns. The two-minute sweep still reads these PRs, so the worst-case delay is the sweep interval.Process each changed PR as its own fingerprint resolves. Keep the
Setdeduplication so one PR that appears in several groups is read once, and keep the reads serialized throughreadOnChange.