Skip to content

[Bug] Session page can crash when sync store becomes unavailable #94

@Astro-Han

Description

@Astro-Han

What happened?

The latest packaged PawWork app showed a renderer crash while viewing a session page: TypeError: Cannot read properties of undefined (reading '0'). The installed app was confirmed as PawWork v0.2.4 under /Applications/PawWork.app.

Initial local inspection maps the top frame get data to packages/app/src/context/sync.tsx, where sync.data returns current()[0]. The stack's session bundle frame maps to packages/app/src/components/session/session-status-panel.tsx, where the status side panel reads sync.data.message[params.id]. That panel appears to be the trigger, but the root cause is likely that the current workspace sync store becomes unavailable at a route, lifecycle, or sidecar reconnect boundary.

Steps to reproduce

Unknown. This has now been observed more than once in the installed v0.2.4 macOS app. The observed context was a session page with the packaged app running from /Applications/PawWork.app.

What did you expect to happen?

The session page should keep rendering, or at least recover gracefully, even if the current workspace store is temporarily unavailable during route changes, workspace lifecycle cleanup, or sidecar reconnects.

Environment

PawWork version: v0.2.4

OS version: macOS 26.3.1 (a), build 25D771280a

Can reproduce again: Sometimes

TypeError: Cannot read properties of undefined (reading '0')
    at get data (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/main-C40ZH7dE.js:69743:26)
    at Object.fn (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/session-CND2DYhc.js:25797:27)
    at runComputation (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:468:22)
    at updateComputation (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:451:3)
    at runTop (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:546:7)
    at runQueue (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:618:42)
    at completeUpdates (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:574:5)
    at runUpdates (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:564:5)
    at batch (file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/styles-Bx0m74eU.js:246:10)
    at file:///Applications/PawWork.app/Contents/Resources/app.asar/out/renderer/assets/main-C40ZH7dE.js:97115:9

Update: reproduced again on 2026-04-21 by clicking the Greeting session (ses_2544c191effeu1Nw5UECHonKbl) from the session list in PawWork v0.2.4. The app entered the same renderer error page with TypeError: Cannot read properties of undefined (reading '0'). This happened while investigating #95, but the crash stack still matches this issue.

Note: a separate packaged-app updater warning was also observed in ~/Library/Logs/PawWork/main.log: repeated ENOENT: no such file or directory, open '/Applications/PawWork.app/Contents/Resources/app-update.yml'. That appears to be a packaging/updater issue rather than the renderer crash root cause, so it may deserve a separate issue if it remains relevant.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High priorityappApplication behavior and product flowsbugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions