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
{{ message }}
Repository navigation
App wedges on startup if the last-opened graph directory is deleted (fails to fallback) #1532
name: Bug Report
about: App wedges on startup if the last-opened graph directory is deleted (fails to fallback)
title: 'App wedges on startup if the last-opened graph directory is deleted (fails to fallback)'
labels: ''
assignees: ''
What Happened?
If the Logseq Desktop app attempts to boot into a graph that has been deleted from the filesystem and unregistered from graphs.edn, it fails to catch the resulting Graph is absent or stopped by deletion IPC error.
Instead of gracefully falling back to the Welcome Screen or the next available graph in the registry, the UI permanently wedges on a blank/loading screen, effectively locking the user out of the application until they manually destroy the Electron Local Storage cache.
Reproduce the Bug
Open Logseq Desktop and load any valid DB graph (e.g., test-graph).
Quit Logseq completely.
In the filesystem, delete the test-graph directory and remove its entry from ~/.logseq/graphs.edn.
Open Logseq Desktop.
Result: The UI freezes on startup. The background worker throws continuous IPC errors in main.log, and there is no UI state provided to select a different valid graph.
Expected Behavior
Logseq should detect that the cached last-opened graph is missing/unregistered, clear the current_repo state from localStorage, and route the user to the Welcome Screen (or load the first valid graph in graphs.edn).
Screenshots
N/A (UI freezes on boot)
Desktop or Mobile Platform Information
OS: macOS (Apple Silicon)
Logseq Version: 2.0.x (DB version)
Additional Context
The main.log spams the following exception during the wedged state:
[error] IPC error: {:event #object[Event [object Object]], :args"[\"~#list\",[\"db-worker-runtime\",\"logseq_db_test-graph\",[\"^ \",\"~:generation\",null]]]"} Error: Graph is absent or stopped by deletion
at fail (.../@logseq/graph-lifecycle/index.cjs:20:23)
at async Object.startGraph (.../@logseq/graph-lifecycle/index.cjs:713:20)
Workaround / Recovery:
The only way to recover the application is to manually destroy the Electron Local Storage cache via the terminal, which resets the last-opened graph memory:
Activity
fix: recover startup when last-opened graph is gone
fix: recover startup when last-opened graph is gone