maxpool 1.24.57 → 1.24.58

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "maxpool",
3
- "version": "1.24.57",
3
+ "version": "1.24.58",
4
4
  "description": "Multi-account Claude Code proxy with adaptive, rate-aware load balancing across Claude accounts",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -1385,7 +1385,20 @@ export class AccountManager {
1385
1385
  const ticket = requestInfo.queueTicket;
1386
1386
  if (!ticket) return true;
1387
1387
  this._reapStaleQueueHead();
1388
- if (this.queueState.waiting[0]?.id !== ticket.id) return false;
1388
+ // BOUNDED HEAD-SKIP (council red-team #5, 2026-10-31): strict FIFO let an
1389
+ // unserveable HEAD (claude-profile with every Claude weekly-walled) block a
1390
+ // serveable follower (all-profile, healthy GLM) for the head's full window —
1391
+ // up to 25 min of "pool dead" while capacity idled. A waiter that has already
1392
+ // waited HEAD_SKIP_MS may be admitted even when tickets ahead of it exist.
1393
+ // Fairness stays: the skip only fires after a real wait, and the head's own
1394
+ // window (queueAndRetry's ceiling) still bounds IT.
1395
+ const HEAD_SKIP_MS = 60_000;
1396
+ if (this.queueState.waiting[0]?.id === ticket.id) {
1397
+ // fast path: unchanged FIFO
1398
+ } else {
1399
+ const waited = Date.now() - (ticket.queuedAt ?? Date.now());
1400
+ if (waited < HEAD_SKIP_MS) return false;
1401
+ }
1389
1402
  const now = Date.now();
1390
1403
  if (now < this.queueState.rampUntil && now - this.queueState.lastAdmissionAt < 250) return false;
1391
1404
  this.queueState.waiting.shift();