From 17dfc6bec4a8b7fd840d479c33e9a7b2449f805d Mon Sep 17 00:00:00 2001 From: Teknium <127238744+teknium1@users.noreply.github.com> Date: Mon, 22 Jun 2026 06:31:39 -0700 Subject: [PATCH] fix(desktop): set AppUserModelID on Windows so notifications fire (#50808) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Windows toast notifications silently no-op unless the app sets an AppUserModelID — new Notification().show() returns without error and nothing appears. The desktop's native-notification system (approval, turn-done, input, etc.) was therefore dead on Windows while working on macOS/Linux. Set the AUMID to the build appId (com.nousresearch.hermes) on Windows right after app.setName, so toasts route to the installed Start Menu shortcut. No-op on macOS/Linux, which don't require it. --- apps/desktop/electron/main.cjs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/apps/desktop/electron/main.cjs b/apps/desktop/electron/main.cjs index 5665e1a8266..50b3c7cf117 100644 --- a/apps/desktop/electron/main.cjs +++ b/apps/desktop/electron/main.cjs @@ -620,6 +620,16 @@ function previewFileMetadata(filePath, mimeType) { } app.setName(APP_NAME) +// Windows toast notifications silently no-op unless an AppUserModelID is set: +// `new Notification().show()` returns without error and nothing appears. The +// AUMID must match the installed Start Menu shortcut's AUMID, which +// electron-builder derives from the build `appId` (com.nousresearch.hermes) — +// keep this string in sync with package.json `build.appId`. macOS/Linux don't +// need this, so gate it on Windows. (Fixes: desktop approval/turn notifications +// never firing on Windows.) +if (IS_WINDOWS) { + app.setAppUserModelId('com.nousresearch.hermes') +} // Seed the native About panel with the live Hermes version. This is refreshed // on every open via the explicit "About" menu handler (refreshAboutPanel), so // an in-place `hermes update` mid-session is reflected without an app restart;