hermes-agent/apps/desktop/src/app
Brian Pasquini 72f522d464 fix(desktop): recover session after sleep/wake gateway restart
When the laptop sleeps and wakes, the WebSocket reconnects but the
gateway's in-memory session table is cleared. The desktop app still
holds the old activeSessionId, so the next prompt.submit call returns
error 4001 ('session not found'), surfaced to the user as:
  'Prompt failed: session not found'

Fix: wrap prompt.submit in a try/catch. On 'session not found', call
session.resume with the durable SQLite session ID (selectedStoredSessionIdRef)
to re-register the session in the gateway, update activeSessionIdRef to
the fresh live session_id, then retry prompt.submit once.

If recovery fails or the error is unrelated, the original error is
re-thrown and surfaces normally.
2026-06-09 03:16:59 -07:00
..
agents feat(desktop): add i18n with Simplified Chinese (zh-Hans) support 2026-06-05 10:32:26 -07:00
artifacts feat(desktop): add i18n with Simplified Chinese (zh-Hans) support 2026-06-05 10:32:26 -07:00
chat chore(salvage): lint fix + AUTHOR_MAP for desktop source-folders PR #40272 2026-06-07 23:44:04 -07:00
command-center feat(desktop): unified overlay design system, BrandMark & onboarding redesign (#40708) 2026-06-06 16:32:47 -05:00
command-palette Refactor desktop settings i18n keys to camelCase 2026-06-06 07:51:44 -07:00
cron fix(desktop): cron overlay mutations sync the sidebar instantly 2026-06-06 16:47:46 -05:00
gateway/hooks fix(desktop): recover chat after sleep/wake by revalidating a stale remote backend 2026-06-07 17:29:12 -07:00
hooks feat(desktop): hover-reveal collapsed sidebars as fixed overlays (#41670) 2026-06-07 22:41:21 -05:00
messaging Show platform sources in desktop sessions 2026-06-07 23:44:04 -07:00
overlays refactor(desktop): converge cron overlay onto profiles' split layout 2026-06-06 16:39:56 -05:00
profiles refactor(desktop): converge cron overlay onto profiles' split layout 2026-06-06 16:39:56 -05:00
right-sidebar Refactor desktop i18n field copy into nested structures 2026-06-06 07:51:44 -07:00
session/hooks fix(desktop): recover session after sleep/wake gateway restart 2026-06-09 03:16:59 -07:00
settings feat(desktop): assignable themes per profile (#42286) 2026-06-08 17:42:17 +00:00
shell fix(desktop): pre-check backend updates in poller; client button first 2026-06-08 08:58:26 -07:00
skills feat(desktop): unified overlay design system, BrandMark & onboarding redesign (#40708) 2026-06-06 16:32:47 -05:00
desktop-controller.tsx fix(desktop): keep a just-finished session visible after switching away (#42285) 2026-06-08 12:32:27 -05:00
index.tsx Add Hermes desktop app (#20059) 2026-05-31 17:46:56 -05:00
layout-constants.ts feat(desktop): hover-reveal collapsed sidebars as fixed overlays (#41670) 2026-06-07 22:41:21 -05:00
model-picker-overlay.tsx Add Hermes desktop app (#20059) 2026-05-31 17:46:56 -05:00
model-visibility-overlay.tsx feat(desktop): inline model picker in the status bar 2026-06-02 19:09:41 -05:00
page-search-shell.tsx feat(desktop): add i18n with Simplified Chinese (zh-Hans) support 2026-06-05 10:32:26 -07:00
routes.ts chore(desktop): zero eslint/typecheck debt + prettier pass (#39100) 2026-06-04 14:10:38 +00:00
types.ts feat(desktop+gateway): remote-gateway file attachments via file.attach 2026-06-09 00:03:49 -07:00
updates-overlay.tsx fix(desktop): close the backend update overlay on success; error on no-return 2026-06-08 08:58:26 -07:00