Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 12 additions & 7 deletions apps/bullmq/src/jobs/pr-review-notification.test.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions apps/bullmq/src/jobs/pr-review-notification.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,10 +266,8 @@ export const prReviewNotificationJob = async (
}

console.warn(

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The cap is reached after the pending-list TTL for ordinary activity: enqueue waits one minute before the first run, then 288 five-minute deferrals put this branch at about 24h01m, while appendPendingEventAndClaimSchedule() expires the list after exactly 24h. By then consumePendingPrReviewActivity() returns an empty batch, so this still drops the feedback in the long-running case. Lower the cap with a buffer or refresh/extend the pending-event TTL while deferring.

`[PrReviewNotification] Task ${data.taskId} never went idle after ${data.deferrals} deferrals, dropping pending review activity for ${data.repository}#${data.prNumber}`,
`[PrReviewNotification] Task ${data.taskId} never went idle after ${data.deferrals} deferrals; delivering pending review activity for ${data.repository}#${data.prNumber}`,
);
await consumePendingPrReviewActivity(target);
return;
}

if (isExecutingTurn && isWorkerHeartbeatStale) {
Expand Down
Loading