agent-dag 1.30.5 → 1.30.6

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.
@@ -5,7 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1" />
6
6
  <title>agents-deck</title>
7
7
  <link rel="icon" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ctext y='84' font-size='84'%3E%E2%97%89%3C/text%3E%3C/svg%3E" />
8
- <script type="module" crossorigin src="/assets/index-9Ja-EEDA.js"></script>
8
+ <script type="module" crossorigin src="/assets/index-CBP4rn8o.js"></script>
9
9
  <link rel="stylesheet" crossorigin href="/assets/index-BHfNMFBX.css">
10
10
  </head>
11
11
  <body>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-dag",
3
- "version": "1.30.5",
3
+ "version": "1.30.6",
4
4
  "description": "Live deck of Claude Code and Codex agents — watch parallel subagents fork, call tools, and return on one calm canvas. Also available as npx ccdeck and npx agent-dag.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -203,6 +203,12 @@ export async function fetchClaudeAccounts({ force = false } = {}) {
203
203
  // this account is worth switching to.
204
204
  headroom: lanes.length ? Math.max(0, 100 - Math.max(...lanes.map(l => l.pct))) : null,
205
205
  fetchedAt: fetchedAtMs,
206
+ // When claude-swap plans to read this account again. It sets the
207
+ // interval per account (180s floor, out to 1800s while a token is
208
+ // recovering from a 429), and every surface — this panel, the TUI,
209
+ // `cswap watch` — inherits the same plan. Showing it turns "collected
210
+ // 13m ago" from a complaint into a schedule.
211
+ nextAt: matches && typeof row.nextPollAt === "number" ? Math.round(row.nextPollAt * 1000) : null,
206
212
  stale: fetchedAtMs == null || now - fetchedAtMs > STALE_AFTER_MS,
207
213
  // Surfaced rather than hidden: a rate-limited or re-login-needed account
208
214
  // is exactly the one the user is about to try switching to.
@@ -412,6 +412,12 @@ async function _doFetch(now, force = false) {
412
412
  store = await nudgeAndReread(store);
413
413
  }
414
414
  if (store && now - store.fetchedAt <= STORE_TRUSTED_MS) {
415
+ // Keep the store moving even when the accounts panel is closed. Without
416
+ // this the numbers only advance while something else asks — claude-swap's
417
+ // own schedule still decides whether this touches the network, and the
418
+ // throttle inside is shared with the accounts panel, so two open panels
419
+ // ask no more often than one.
420
+ if (!force) requestCollection().catch(() => {});
415
421
  _cache = store; _cacheAt = now;
416
422
  _lastGood = store;
417
423
  return store;