• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

cjrh / deadpool / 46489930918
89%

Build:
DEFAULT BRANCH: main
Ran 30 Nov 2026 06:59PM UTC
Jobs 1
Files 13
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

30 Nov 2026 06:57PM UTC coverage: 88.539% (+0.2%) from 88.374%
46489930918

push

github

web-flow
Hand out a worker that has run a task before one that has not (#456)

With `idle_timeout`, a worker that has just been started goes to the
front of the idle queue, so the next task can be given one that is still
starting while warm ones are idle. This keeps a worker that has run
nothing behind those that have.

**Measured** with three workers, a 2 s start-up, recycling after two
tasks, and one task at a time: on `main`, the third and fifth of six
tasks waited 1.9 s each. With this change none waits.

**What changes, only with `idle_timeout` and `min_workers`:**

- A worker that has run a task is handed out before one that has not.
Among workers that have run a task, the most recently used still goes
first.
- The longest-idle worker still retires first. The queue is no longer in
age order, so the timer now picks the oldest by its timestamp. Looking
only at the front would let a new worker hide expired ones behind it
until it expired too.

A worker that has run nothing waits behind even if it finished starting
long ago, so it is used only when no other is idle.

**Tests:** a task is not given a worker held in its initializer while a
warm one is idle, and a new worker does not stop expired ones from
retiring. The first fails on `main`; the second fails if the timer looks
only at the front. The full suite passes on Python 3.10 to 3.14 and on
3.14t with the GIL off (226 each).

801 of 991 branches covered (80.83%)

Branch coverage included in aggregate %.

14 of 14 new or added lines in 1 file covered. (100.0%)

2745 of 3014 relevant lines covered (91.07%)

5.44 hits per line

Jobs
ID Job ID Ran Files Coverage
1 46489930918.1 30 Nov 2026 07:00PM UTC 13
88.54
GitHub Action Run
Source Files on build 46489930918
  • Tree
  • List 13
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • 56911b5e on github
  • Prev Build on main (#46475820382)
  • Next Build on main (#46490229994)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc