Repository navigation
Fix: make session-timeout test race-free under runner load - #1634
Conversation
|
Warning Review limit reached
Next review available in: 16 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
c3868bb to
787a377
Compare
The driver armed the session timeout at a fixed 3 s, racing the child's pytest startup: on a loaded shared runner the startup can exceed 3 s, so the timeout dumps the child before it forks and the grandchild sentinel never appears. Tuning the constant (30 s, 300 s) only widens the race window and slows the test. Instead the dump is now event-driven: the grandchild writes a ready marker the moment it reaches the sentinel, and a driver watcher fires the real conftest handler (os.kill(self, SIGALRM)) when the marker appears. The session timeout is demoted to a 60 s fail-safe bound, same as the driver's existing subprocess timeout. The test stays fast (startup + epsilon) and cannot race the startup at any load.
The driver armed the session timeout at a fixed 3 s, racing the child's pytest startup: on a loaded shared runner (the cpu lane runs 5 T1 jobs in parallel on one box) startup can exceed 3 s, so the timeout dumps the child before it forks and
_grandchild_deadlock_sentinelnever appears. Tuning the constant (30 s, 300 s) only widens the race window and slows the test.\n\nInstead the dump is now event-driven: the grandchild writes a ready marker the moment it reaches the sentinel, and a driver watcher thread fires the real conftest handler (os.kill(self, SIGALRM)) when the marker appears. The session timeout is demoted to a 60 s fail-safe bound (same as the driver's existing subprocess timeout). The test stays fast (startup + epsilon) and cannot race the startup at any load; a real regression still fails at the 60 s bound with the sentinel missing from the dump.