Skip to content

fix(desktop): avoid local profile REST backend spawns#61033

Draft
embwl0x wants to merge 1 commit into
NousResearch:mainfrom
embwl0x:agent/desktop-single-profile-backend
Draft

fix(desktop): avoid local profile REST backend spawns#61033
embwl0x wants to merge 1 commit into
NousResearch:mainfrom
embwl0x:agent/desktop-single-profile-backend

Conversation

@embwl0x

@embwl0x embwl0x commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes #61023.

Hermes One can start an extra isolated dashboard backend for a local non-primary profile during startup because the Electron hermes:api proxy treated every request.profile as a backend-process routing key. Profile-scoped startup/config/session reads then call ensureBackend(profile), which launches a pooled --profile <name> dashboard/serve backend even though the primary machine dashboard can serve local profiles through ?profile=.

This keeps ordinary local-profile REST on the primary backend and appends ?profile=<name> to the proxied path instead. Per-profile remote overrides and app-global remote mode still route through profile descriptors so remote hosts keep working. Live chat sockets still use the existing lazy secondary backend path; this only changes REST routing.

Refresh note

Rebuilt onto current main after the desktop app moved from CommonJS Electron files to TypeScript/ESM. The routing helper and IPC coverage now live in the current .ts files.

Duplicate / overlap check

Verification

  • cd apps/desktop && node --import tsx --test electron/connection-config.test.ts electron/profile-delete-respawn.test.ts — 57 passed
  • npm --prefix apps/desktop run typecheck
  • git diff --check origin/main..HEAD
  • gitleaks git --log-opts='origin/main..HEAD' --redact . — no leaks found

@alt-glitch alt-glitch added type/bug Something isn't working comp/desktop Electron desktop app (apps/desktop/*) P3 Low — cosmetic, nice to have labels Jul 8, 2026
@embwl0x embwl0x force-pushed the agent/desktop-single-profile-backend branch from d21da36 to bbb93d9 Compare July 9, 2026 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/desktop Electron desktop app (apps/desktop/*) P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Hermes One v0.7.3 spawns two dashboard backends simultaneously when multiple profiles exist

2 participants