Conversation
4df4e9d to
90f60ab
Compare
90f60ab to
50183f1
Compare
|
Thanks for tracing the profile across the Desktop session-entry surfaces. The premise is confirmed on current main: a fresh secondary renderer starts with an empty The proposed optional route hint directly addresses that cold path and preserves the existing fallback discovery behavior. The focused changes align with Electron's existing profile-aware API routing ( This is an automated hermes-sweeper review. |
50183f1 to
65c201f
Compare
65c201f to
cfd038e
Compare
|
Thanks for tracing this across every Desktop session-entry surface — the map you built of where ownership gets dropped was accurate, and it's what made the residual gap easy to find. We ended up fixing it from the other side. #74033 makes One piece of your PR wasn't covered by that, though: Closing as superseded — the remaining diff here is a 149-file rebase against a fix that's already landed. |
`hermes.desktop.lastSessionId` is keyed by owning profile (143942d), but `hermes.desktop.lastRoute` stayed global -- and cold-start restore prefers the route over the id. A session route embeds a session id in its path, so relaunching under profile B navigated straight into a session owned by profile A, bypassing the id scoping entirely (NousResearch#67603 family). Key the remembered route by the same owner the id already uses (rememberedSessionProfile), read it back for the active profile on restore, and keep the default profile on the original unsuffixed key so existing installs' remembered route survives the upgrade. Salvaged from the profile-hint work in NousResearch#49619, which threaded an explicit profile through every route/IPC/window surface to reach the same end. The server now stamps session ownership unconditionally (NousResearch#74033), so the resolver already gets the right answer and only this persisted key was left crossing profiles. Co-authored-by: d31tcjg <d31tcjg@users.noreply.github.com>
|
Thank you for the clear explanation, and for salvaging the remembered-route fix with credit. I’m glad the investigation and session-entry mapping helped improve Hermes, even though the final solution landed through a different path. Happy to have contributed. 🙂 |
`hermes.desktop.lastSessionId` is keyed by owning profile (9c3ff21), but `hermes.desktop.lastRoute` stayed global -- and cold-start restore prefers the route over the id. A session route embeds a session id in its path, so relaunching under profile B navigated straight into a session owned by profile A, bypassing the id scoping entirely (NousResearch#67603 family). Key the remembered route by the same owner the id already uses (rememberedSessionProfile), read it back for the active profile on restore, and keep the default profile on the original unsuffixed key so existing installs' remembered route survives the upgrade. Salvaged from the profile-hint work in NousResearch#49619, which threaded an explicit profile through every route/IPC/window surface to reach the same end. The server now stamps session ownership unconditionally (NousResearch#74033), so the resolver already gets the right answer and only this persisted key was left crossing profiles. Co-authored-by: d31tcjg <d31tcjg@users.noreply.github.com>
`hermes.desktop.lastSessionId` is keyed by owning profile (143942d), but `hermes.desktop.lastRoute` stayed global -- and cold-start restore prefers the route over the id. A session route embeds a session id in its path, so relaunching under profile B navigated straight into a session owned by profile A, bypassing the id scoping entirely (NousResearch#67603 family). Key the remembered route by the same owner the id already uses (rememberedSessionProfile), read it back for the active profile on restore, and keep the default profile on the original unsuffixed key so existing installs' remembered route survives the upgrade. Salvaged from the profile-hint work in NousResearch#49619, which threaded an explicit profile through every route/IPC/window surface to reach the same end. The server now stamps session ownership unconditionally (NousResearch#74033), so the resolver already gets the right answer and only this persisted key was left crossing profiles. Co-authored-by: d31tcjg <d31tcjg@users.noreply.github.com>
`hermes.desktop.lastSessionId` is keyed by owning profile (7790df2), but `hermes.desktop.lastRoute` stayed global -- and cold-start restore prefers the route over the id. A session route embeds a session id in its path, so relaunching under profile B navigated straight into a session owned by profile A, bypassing the id scoping entirely (NousResearch#67603 family). Key the remembered route by the same owner the id already uses (rememberedSessionProfile), read it back for the active profile on restore, and keep the default profile on the original unsuffixed key so existing installs' remembered route survives the upgrade. Salvaged from the profile-hint work in NousResearch#49619, which threaded an explicit profile through every route/IPC/window surface to reach the same end. The server now stamps session ownership unconditionally (NousResearch#74033), so the resolver already gets the right answer and only this persisted key was left crossing profiles. Co-authored-by: d31tcjg <d31tcjg@users.noreply.github.com>
`hermes.desktop.lastSessionId` is keyed by owning profile (143942d), but `hermes.desktop.lastRoute` stayed global -- and cold-start restore prefers the route over the id. A session route embeds a session id in its path, so relaunching under profile B navigated straight into a session owned by profile A, bypassing the id scoping entirely (NousResearch#67603 family). Key the remembered route by the same owner the id already uses (rememberedSessionProfile), read it back for the active profile on restore, and keep the default profile on the original unsuffixed key so existing installs' remembered route survives the upgrade. Salvaged from the profile-hint work in NousResearch#49619, which threaded an explicit profile through every route/IPC/window surface to reach the same end. The server now stamps session ownership unconditionally (NousResearch#74033), so the resolver already gets the right answer and only this persisted key was left crossing profiles. Co-authored-by: d31tcjg <d31tcjg@users.noreply.github.com>
Summary
getSession, message fallback, andsession.resumethrough the same profile hint while preserving legacy fallback behavior when the hint is absent or stale.Motivation
Desktop aggregates sessions from multiple profiles. A row owned by a non-active profile could previously navigate or open a secondary window using only its session ID. Resume then probed the active/default profile, leaving Desktop stuck loading or reporting
session not foundeven though the session existed in its owning profile.This update covers the complete current Desktop path rather than only the original sidebar/resume implementation. It also adapts the change to the split
use-session-actions/index.tsandutils.tslayout now onmain.Compatibility
Testing
npm run test:ui --workspace apps/desktop -- src/store/windows.test.ts src/app/chat/sidebar/sessions-section.test.tsx src/app/routes.test.ts src/app/session/hooks/use-route-resume.test.tsx src/app/session/hooks/use-session-actions.test.tsxnpm run test:desktop:platforms --workspace apps/desktop -- electron/session-windows.test.tsnpm run typecheck --workspace apps/desktopgit diff --check origin/main...HEAD