Commit graph

4201 commits

Author SHA1 Message Date
Rod Boev
52a030503b Exercise real cache diagnostics instead of source-text checks 2026-06-13 22:36:25 -04:00
Rod Boev
07641dc987 Keep session list singleflight stable for WebUI-only views 2026-06-13 22:36:25 -04:00
Rod Boev
f7dbf7df6a Invalidate cached session lists when backing stores change 2026-06-13 22:36:25 -04:00
Rod Boev
c3750fe361 perf(sidebar): cache and single-flight /api/sessions payloads (#3791) 2026-06-13 22:36:25 -04:00
nesquena-hermes
1643d660b5
Merge pull request #4157 from nesquena/stage-4156
Release NQ (v0.51.404): PWA multi-window connection-pool saturation fix (#4151)
2026-06-13 18:36:34 -07:00
nesquena-hermes
b8a84f13e1 docs(changelog): stamp #4151 PWA multi-window SSE fix as v0.51.404 (Release NQ) 2026-06-14 01:33:14 +00:00
Nathan Esquenazi
266d9cdbd3 fix(sse): guard gateway reopen on focus so transient blur can't thrash it (#4151)
The #4151 focus hook reopened both global sidebar streams on `focus` with a
bare `startGatewaySSE()`. But `startGatewaySSE()` is NOT idempotent — it begins
with an unconditional `stopGatewaySSE()` (sessions.js:3778), which closes the
live gateway EventSource, cancels its poll fallback (`stopGatewayPollFallback`),
and resets `_gatewayProbeInFlight` / `_gatewaySSEWarningShown`.

So on a transient blur shorter than the 1s debounce — where the blur-close
timer is cleared on the following focus and the stream was never torn down —
the focus handler still dropped and reconnected the gateway on every
window-switch, cancelling its fallback and resetting probe/warning state. That
is the exact thrash the debounce exists to prevent, in the multi-window PWA
scenario this PR targets. (`ensureSessionEventsSSE()` is already idempotent via
`if(_sessionEventsSSE) return`, so the session-events stream was unaffected;
only the gateway churned. greptile P1.)

Guard the reopen on the gateway actually being closed: `if(!_gatewaySSE)
startGatewaySSE()`, mirroring the session-events idempotency. A sustained blur
(timer fires → both streams closed) still reopens the gateway on focus; a
transient blur leaves the still-open gateway untouched. Verified with a
blur/focus/timer harness (transient → no teardown/reconnect; sustained → close
then reopen; CLI-disabled → stays closed) and a new regression guard
`test_focus_reopen_does_not_thrash_the_gateway_stream`.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-13 18:07:12 -07:00
nesquena-hermes
408dbeb4f0 fix(sse): close global sidebar streams on PWA window blur (#4151)
Two side-by-side PWA standalone windows saturate the browser's per-origin
HTTP/1.1 connection limit, causing 'Request timed out' toasts to cycle every
~30s. The idle-SSE close added in #3992/#3996 keys off the Page Visibility API
(visibilitychange / document.hidden), but a PWA standalone window does not
reliably fire visibilitychange when it loses focus to another window of the
same app -- document.hidden only flips on minimize. So both windows stay
'visible', each holds its two global sidebar SSE streams (session-events +
gateway) open, 2x3 = 6 hits the connection cap, and subsequent fetch() calls
(the 30s background polls) queue behind the saturated pool and time out.

The two global sidebar streams now also close on a sustained window blur (gated
on document.hasFocus(), the signal visibilitychange misses) and reopen --
catching up the session list -- on focus, via a shared _sidebarSseBackgrounded()
predicate and a debounced _installSidebarSseFocusHook().

The per-session live stream (messages.js startSessionStream) is intentionally
left visibility-only: it carries live bg_task_complete toasts and
server_turn_started live-view that an unfocused-but-visible window must still
receive (the OS-notification path is gated on document.hidden, so the in-app
toast is the only completion signal a visible-unfocused window gets). Closing
it on blur would regress the multi-window live-view UX.

Reported by @ddiall with a thorough root-cause analysis.

Co-authored-by: ddiall <ddiall@users.noreply.github.com>
2026-06-14 00:54:28 +00:00
nesquena-hermes
ebf778edd3
Merge pull request #4155 from nesquena/stage-4143
Release NP (v0.51.403): notification click reuses existing chat tab (#4109)
2026-06-13 17:47:27 -07:00
nesquena-hermes
219635f8ae docs(changelog): stamp #4109 notification focus-existing-tab as v0.51.403 (Release NP) 2026-06-14 00:26:15 +00:00
nesquena-hermes
e044a2e938 Merge #4143 (focus existing chat tab on notification click, #4109) onto master 2026-06-14 00:25:09 +00:00
nesquena-hermes
ca4b82c126
Merge pull request #4149 from nesquena/stage-4112b
Release NM (v0.51.400): skill bundles in WebUI slash commands (#4087)
2026-06-13 16:25:30 -07:00
nesquena-hermes
e069a2dbcc docs(changelog): stamp #4087 skill-bundle slash commands (precedence-fixed) as v0.51.400 (Release NM) 2026-06-13 23:14:31 +00:00
nesquena-hermes
5812df5f7b Merge #4112 (skill bundles in WebUI slash commands, #4087) onto master 2026-06-13 23:13:28 +00:00
Rod Boev
d7e8f70423 fix(commands): block transient bundle shadowing 2026-06-13 18:53:46 -04:00
nesquena-hermes
3e87b620f5
Merge pull request #4147 from nesquena/stage-3940v2
Release NL (v0.51.399): per-home provider probe-worker pool, race-safe (#3787)
2026-06-13 15:15:34 -07:00
nesquena-hermes
c0ea19407b docs(changelog): stamp #3940 v2 (claim-under-pool-lock) as v0.51.399 (Release NL) 2026-06-13 22:05:58 +00:00
nesquena-hermes
fa19eae6d1 Merge #3940 v2 (claim probe workers under pool lock, #3787) onto master 2026-06-13 22:05:05 +00:00
nesquena-hermes
4eec7c3fec
Merge pull request #4145 from nesquena/stage-3998v2
Release NK (v0.51.398): auto-generate titles for imported CLI sessions (#3987)
2026-06-13 15:02:56 -07:00
nesquena-hermes
961bfbd2ba docs(changelog): stamp #3987 v2 (reload-before-save) as v0.51.398 (Release NK) 2026-06-13 21:47:42 +00:00
nesquena-hermes
4f1ce2661e Merge #3998 v2 (imported-session titles + reload-before-save fix, #3987) onto master 2026-06-13 21:46:36 +00:00
Matt Van Horn
c3f4d33392
fix: focus the existing chat tab when a notification is clicked instead of opening a new tab
Fixes #4109
2026-06-13 14:42:41 -07:00
Rod Boev
6a27b414c6 Preserve imported title rework without breaking route invariants 2026-06-13 17:34:22 -04:00
nesquena-hermes
b2d32924a4
Merge pull request #4142 from nesquena/stage-4072
Release NJ (v0.51.397): wire /credits through WebUI command dispatch (#4071)
2026-06-13 14:28:01 -07:00
nesquena-hermes
e0e4ebfde5 docs(changelog): stamp #4071 /credits WebUI command as v0.51.397 (Release NJ) 2026-06-13 21:16:33 +00:00
nesquena-hermes
f7047d4d19 Merge #4072 (wire /credits through WebUI command dispatch, #4071) onto master 2026-06-13 21:15:22 +00:00
nesquena-hermes
1557f80f83
Merge pull request #4141 from nesquena/stage-4139
Release NI (v0.51.396): longer timeout for full-history session loads (#4139)
2026-06-13 13:53:12 -07:00
Rod Boev
e1ec41b32c fix(session): reload latest imported session before title save (#3987) 2026-06-13 16:47:57 -04:00
nesquena-hermes
31af2da234 docs(changelog): stamp #4139 full-history-load timeout as v0.51.396 (Release NI) 2026-06-13 20:44:06 +00:00
Rod Boev
bb8d5e9587 fix(providers): claim probe workers under the pool lock (#3787) 2026-06-13 16:42:43 -04:00
nesquena-hermes
fd972ff2a5 Merge #4139 (extend timeout for full-history session loads) onto master 2026-06-13 20:42:17 +00:00
ai-ag2026
cea9d42fcc fix: extend timeout for full history session loads
(cherry picked from commit 27cbff974eeaa58780d91fb4f25802cf0ac76381)
2026-06-13 22:37:19 +02:00
nesquena-hermes
eeda18c764
Merge pull request #4140 from nesquena/stage-4011
Release NH (v0.51.395): push source filters into agent session scans (#3930)
2026-06-13 13:33:24 -07:00
nesquena-hermes
c117d57706 docs(changelog): stamp #3930 source-filter pushdown as v0.51.395 (Release NH) 2026-06-13 20:18:54 +00:00
nesquena-hermes
12107f3ae5 Merge #4011 (push source filters into agent session scans, #3930) onto master 2026-06-13 20:17:51 +00:00
nesquena-hermes
5c2b5c1b7b
Merge pull request #4136 from nesquena/stage-4131
Release NG (v0.51.394): document-title attention badge for pending prompts (#4121)
2026-06-13 12:35:02 -07:00
nesquena-hermes
42e5d1b02e
Merge branch 'master' into stage-4131 2026-06-13 12:31:15 -07:00
nesquena-hermes
5a33a51cec Merge #4131 (badge pending prompts in document title, #1694) onto master
# Conflicts:
#	CHANGELOG.md
2026-06-13 19:19:24 +00:00
nesquena-hermes
3ee2f5d693
docs: refresh contributor tally for v0.51.390 (248 contributors) (#4132)
* docs: refresh contributor tally for v0.51.390 (248 contributors)

Regenerated via scripts/regen_contributors.py after fixing three real
over-counting bugs in the generator (release-vehicle PR# leak, reporter
false-positives, prose-token leakage — see workspace commit). Net:

- 248 contributors / 1092 credits (corrected; the prior generator inflated
  this with ~106 spurious release-vehicle co-author credits + reporter mentions)
- CONTRIBUTORS.md now recognizes 3+ PR contributors in ranked tables and lists
  everyone with 1-2 PRs in a combined roll, so nobody already credited is dropped
- README top-10 snapshot + notable-contribution counts updated to match
  (franksong 180, Michaelyklam 118, rodboev 83 [new], ai-ag2026 75, bergeouss 70)

Every name in the tally is authorship-verified (merged PR, CHANGELOG attribution,
or a Co-authored-by trailer); bug reporters / relayers / confirmers are no longer
miscredited as authors.

* docs: add generated-region markers so the contributor tally regenerates cleanly

Wraps the machine-generated tables in CONTRIBUTORS.md + README.md with
<!-- BEGIN/END GENERATED CONTRIBUTORS --> markers. scripts/regen_contributors.py
--apply now splices fresh tables between them on each run while leaving the
hand-written prose (How credit is tracked, Special thanks, README Notable
contributions) untouched. Verified idempotent: a second --apply is a no-op.
This is what the weekly refresh cron runs.

Tally re-synced to current master: 248 contributors / 1093 credits.

---------

Co-authored-by: nesquena-hermes <nesquena-hermes@users.noreply.github.com>
Co-authored-by: Nathan Esquenazi <nesquena@gmail.com>
2026-06-13 12:18:21 -07:00
nesquena-hermes
e389107954
Merge pull request #4135 from nesquena/stage-4127
Release NF (v0.51.393): run /yolo immediately while busy (#467 follow-up)
2026-06-13 12:14:58 -07:00
nesquena-hermes
9240a7d429 docs(changelog): stamp #4127 /yolo busy-send as v0.51.393 (Release NF) 2026-06-13 19:05:44 +00:00
Rod Boev
e5640a42b9 Keep prompt-attention title badges from breaking title ownership 2026-06-13 15:05:03 -04:00
Rod Boev
4329768288 feat(topbar): badge pending prompts in document title (#4121) 2026-06-13 15:04:20 -04:00
nesquena-hermes
45b88b55b7 Merge #4127 (run /yolo immediately on busy send path) onto master 2026-06-13 19:04:13 +00:00
nesquena-hermes
ebe9fff809
Merge pull request #4134 from nesquena/stage-4130
Release NE (v0.51.392): align WebUI reasoning efforts to agent set, drop max (#3505 follow-up)
2026-06-13 12:02:05 -07:00
nesquena-hermes
30cc15975e fix(#4130): coerce stale 'max' in get_reasoning_status read path too (Codex catch)
get_reasoning_status() returned the raw config reasoning_effort, so a stale saved
'max' surfaced on boot/status/chip even though streaming coerces it to xhigh. Now
routes the status value through coerce_reasoning_effort_for_model() with the resolved
model/provider/base_url, so all read paths agree. Added a stale-max->xhigh status
regression test.
2026-06-13 18:50:00 +00:00
nesquena-hermes
bf6efb1a05 docs(changelog): stamp #4130 reasoning-effort alignment (drop max) as v0.51.392 (Release NE) 2026-06-13 18:44:41 +00:00
nesquena-hermes
540af21444 Merge #4130 (hide unsupported max reasoning effort from WebUI) onto master 2026-06-13 18:43:11 +00:00
nesquena-hermes
80cb179625
Merge pull request #4129 from nesquena/stage-4126
Release ND (v0.51.391): Stable Assistant Turn Anchors renderer snapshot adapter (inert) (#4126)
2026-06-13 11:40:05 -07:00
Rod Boev
95bb9ebe66 Keep stale max configs on the supported path 2026-06-13 14:33:26 -04:00