Repository navigation
Backlog
Labels
See ResearchFollow the research: https://github.com/coreyolson/research
Description
A review reservation is written for reviewLease (30 minutes by default), but its job lease is taken for 2 minutes. The next reserve by any reviewer clears it once those 2 minutes pass without a fresh heartbeat. Reviewers waiting on a long check lose their item and another reviewer starts over.
rows:
- C7
- V15
env: "Node 26, Ubuntu 26.04 VM, one board with about 20 seats; reviewers wait on E2E runs of 20 minutes or more"
version: "0.9.5"
ran: "pullboard next --verify by one reviewer while another reviewer holds a reservation and waits on a long check"
cause: "reserveWithin() in packages/store/src/io/board/reserve/review.js sets item_review_until to now + leaseMs (reviewLease), then holdReviewLease() in packages/store/src/io/board/review/lease.js calls reserveReview() and renewReview() without leaseMs, so the job lease uses LEASE_MS (120000) from packages/jobs/src/logic/rules.js. sweepLapsedReviews() runs on every reserve and clears any reservation whose job lease lapsed while item_review_until is still in the future, unless the reviewer heartbeat is newer than 2 minutes."
blocks: "review of any item that needs a long check; on one board 18 of 53 releases in 4 hours were REVIEW_LEASE_LAPSED, some after 12 seconds past the job lease, and the same four items were re-reviewed by new sessions about 90 times in 8 hours"
compat:
- A reservation whose reviewer is really gone still frees itself.
- next without --verify still lapses an unstarted review in 5 minutes.
bar:
- 1: a reservation made with reviewLease 30m is not cleared by another reviewer's reserve 3 minutes later when its reviewer sent no heartbeat [test]
- 2: a reservation is cleared once reviewLease passes with no heartbeat or renewal [test, kept]
check:
- 1: packages/store/tests/io/board/review/lease.test.js > job lease follows the reservation lease
- 2: packages/store/tests/io/board/review/lease.test.js > silent reviewer loses the reservation after reviewLease
error: |
{"review":true,"reason":"Review silent for 0 minutes; its reservation lease lapsed.","reasonCode":"REVIEW_LEASE_LAPSED","lapsed":{"reviewer":"review-47","lapsedMs":12511}}Metadata
Metadata
Assignees
Labels
See ResearchFollow the research: https://github.com/coreyolson/research
Activity
edkog commentedon Nov 24, 2026
Workaround we run locally on 0.9.5, in case it helps the fix:
holdReviewLease()in packages/store/src/io/board/review/lease.js passes aleaseMstorenewReview()andreserveReview(). ThatleaseMsis the time left until the item'sitem_review_until, so the job lease lasts as long as the reservation, never less than the 2-minuteLEASE_MS. A reviewer that really goes away still loses the item whenitem_review_untilpasses.More data from the same board on 2026-11-24: about 45% of all releases were REVIEW_LEASE_LAPSED (40 of 79 in one 6 h window, about 26 of 57 in the next).