You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The data-durability audit on PR #202 verified the Electron main-process changes (preload bridge, IPC disk backups, quit-flush lifecycle, app:// protocol handler) using a headless Linux setup: xvfb-run + a local Electron binary + Chrome DevTools Protocol / Node inspector to drive the renderer and main process without a real display or input.
That verification caught two real bugs purely because it exercised an actual running process instead of just reading the code:
app.getAppPath() resolved to dist-electron/ (the entry script's own directory) instead of the project/app root, breaking app://localhost/ — i.e. the packaged production app would never have loaded. Fixed by switching to __dirname + a relative sibling path to dist/.
The quit-flush handshake was wired to app's before-quit event, which fires after the last window (and its renderer) is already destroyed on the normal "click the window's close button" path — so the disk-backup-on-quit flush never actually ran in the most common real-world quit scenario. Fixed by hooking the window's own close event instead.
Both fixes were verified working in the headless Linux environment, and one developer has since confirmed pnpm run electron:preview works locally without issue. However, the actual packaged build artifacts (.dmg for macOS, NSIS installer for Windows) produced by electron-builder have not been installed and launched on real macOS or Windows as part of this work — only the unpacked dev/preview path has been exercised end-to-end.
Ask
Once the next release builds the desktop installers (.github/workflows/electron-release.yml), do a manual smoke test on at least one real macOS machine and one real Windows machine:
Install from the .dmg / NSIS installer (not just electron:preview).
Confirm the app loads (the asar-packaged app:// protocol path, which is where the getAppPath() bug specifically lived).
Click the window's close button and confirm the app doesn't hang and a fresh backup file appears in the OS user-data backups folder before it fully quits.
macOS only: with the window closed but the app still in the dock, reopen via the dock icon and confirm a normal close-and-flush cycle works again (covers the isQuittingForReal/quitFlushPending reset added in PR feat: Add undo for hard deletes and Electron disk backups #202's follow-up fix for window-reopen state).
Origin
Surfaced during the data-durability audit on claude/desktop-election-audit-szdu5u (PR #202).
Background
The data-durability audit on PR #202 verified the Electron main-process changes (preload bridge, IPC disk backups, quit-flush lifecycle,
app://protocol handler) using a headless Linux setup:xvfb-run+ a local Electron binary + Chrome DevTools Protocol / Node inspector to drive the renderer and main process without a real display or input.That verification caught two real bugs purely because it exercised an actual running process instead of just reading the code:
app.getAppPath()resolved todist-electron/(the entry script's own directory) instead of the project/app root, breakingapp://localhost/— i.e. the packaged production app would never have loaded. Fixed by switching to__dirname+ a relative sibling path todist/.app'sbefore-quitevent, which fires after the last window (and its renderer) is already destroyed on the normal "click the window's close button" path — so the disk-backup-on-quit flush never actually ran in the most common real-world quit scenario. Fixed by hooking the window's owncloseevent instead.Both fixes were verified working in the headless Linux environment, and one developer has since confirmed
pnpm run electron:previewworks locally without issue. However, the actual packaged build artifacts (.dmgfor macOS, NSIS installer for Windows) produced byelectron-builderhave not been installed and launched on real macOS or Windows as part of this work — only the unpacked dev/preview path has been exercised end-to-end.Ask
Once the next release builds the desktop installers (
.github/workflows/electron-release.yml), do a manual smoke test on at least one real macOS machine and one real Windows machine:.dmg/ NSIS installer (not justelectron:preview).app://protocol path, which is where thegetAppPath()bug specifically lived).isQuittingForReal/quitFlushPendingreset added in PR feat: Add undo for hard deletes and Electron disk backups #202's follow-up fix for window-reopen state).Origin
Surfaced during the data-durability audit on
claude/desktop-election-audit-szdu5u(PR #202).