Skip to content

Fix launch crash and empty-library bugs; add multiple libraries + manifest inference (1.1.0) - #1

Merged
AxialForge merged 8 commits into
mainfrom
claude/shopdeck-file-selection-bug-j00q7y
Aug 1, 2026
Merged

AxialForge merged 8 commits into
mainfrom
claude/shopdeck-file-selection-bug-j00q7y

Conversation

@AxialForge

@AxialForge AxialForge commented Jul 31, 2026 •

Copy link
Copy Markdown
Owner

Started from the reported bug — "the app won't let me see or select files," a fatal dialog on launch — and fixed the full chain it uncovered, verified on a real Windows + OneDrive setup. Full write-up in FIXES.md.

Bugs fixed

1. Launch crash — UNKNOWN: unknown error, watch (44a3ec6)
The library watcher's recursive fs.watch only guarded its synchronous setup. On Windows, a recursive watch over an OneDrive-synced folder (the default Documents root) or a network share fires an asynchronous error event with no listener, so Node re-throws it and the main process dies before the window renders. Fix: attach an 'error' listener (degrade to manual refresh) + main-process uncaughtException/unhandledRejection guards.

2. Unreachable library hung the UI on "Loading…" (d730fcc)
Every IPC handler funnels through libraryRoot(), whose fs.mkdir threw on an offline share/deleted folder; library:scan rejected and the renderer's reload() had no try/catch. Fix: libraryRoot() never throws, library:scan returns a soft error object, and the renderer shows a dismissable error banner with Retry.

3. Folder shown but 0 modules — OneDrive on-demand files (0aa5aee)
OneDrive "Files On-Demand" placeholders are reparse points that readdir reports as symlinks, so entry.isFile() was false and the scan skipped every module while still listing the directory. Fix: an entryKind() helper that stat-resolves ambiguous entries (metadata only, no download), plus a self-diagnosing empty state (htmlCount + skip reasons).

4. Standalone-tool timelines had no manifest (627ec6a)
Files exported by the standalone tool carry a <title> and a const DATA = {…} but no module-manifest, so they were correctly found but rejected. Fix: ShopDeck now infers a manifest when one is absent — id from the filename, title from <title>, and for tool-swap timelines the part/event-count/date-range/tags from DATA. Inferred modules are flagged inferred: true (card shows "· no manifest"); real manifests stay authoritative. Import no longer rejects manifest-less HTML.

Features

  • Multiple libraries + rename (d730fcc). New pure-Node electron/libraries.js: a library is a named pointer { id, name, root }. Rename edits the app-side label only (the folder on disk is never renamed); remove just unlinks it (files stay); the last library can't be removed; legacy single-root installs migrate automatically. New IPC libraries:list/add/rename/remove/switch/reveal, a top-bar switcher, and a Libraries manager in Settings.
  • On-demand Windows installer build (d8ec34c, c967885). build-windows.yml builds NSIS + portable installers on windows-latest and uploads them as a private artifact — used for the test builds throughout. release.yml (public release on a v* tag) is unchanged.

Version

Bumped to 1.1.0 (3a363df) — minor, since it adds features on top of the fixes.

Tests

test/library.test.mjs + test/libraries.test.mjs — 24 pure-Node tests passing, including OneDrive/symlink discovery and manifest inference (timeline + generic). CI (node --test, Ubuntu) and the Windows installer build are both green. Electron can't be launched in the CI/agent environment (install scripts blocked, per CLAUDE.md); each fix was confirmed on the user's real Windows machine via a fresh installer build, ending with all 9 timelines showing correctly.

🤖 Generated with Claude Code

https://claude.ai/code/session_019rbmo7LSmxRtFf5zwfvw83

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant