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
In composer shell mode (mod+shift+x), sending any command — including successful ones like gh --help and nonexistent ones like absolutelyfake — triggers a renderer crash:
TypeError: switchFunc(...) is not a function
at Switch.createMemo.name [as fn]
at runComputation
at updateComputation
...
Full stack from the session:
TypeError: switchFunc(...) is not a function
at Switch.createMemo.name [as fn] (http://localhost:5173/@fs/.../node_modules/.vite/deps/chunk-VL2SL2GY.js?v=db12a2de:1549:29)
at runComputation (.../chunk-VL2SL2GY.js:734:22)
at updateComputation (.../chunk-VL2SL2GY.js:717:3)
at runTop (.../chunk-VL2SL2GY.js:827:7)
at lookUpstream (.../chunk-VL2SL2GY.js:951:87)
at runTop (.../chunk-VL2SL2GY.js:811:74)
at runUserEffects (.../chunk-VL2SL2GY.js:924:18)
at runUpdates (.../chunk-VL2SL2GY.js:844:17)
at completeUpdates (.../chunk-VL2SL2GY.js:896:17)
#174 addressed renderer crashes on failed shell commands by replacing Switch with Show inside packages/ui/src/components/basic-tool.tsx. Manual reverification shows that (a) the crash now also fires on successful commands and (b) it originates from a different <Switch> than the one #174 patched — basic-tool.tsx no longer contains <Switch> in the current tree, so the switchFunc(...) is not a function stack must be from another message-part or tool render path.
Verified
Reproducible on a clean origin/dev worktree (checked at 4274751ab9, HEAD at issue filing). Not introduced by feat(app): home redesign per #151 #180; #180 does not modify packages/ui or any <Switch> rendering code.
Next steps
Identify the specific <Switch> whose <Match when={...}> predicate collapses to undefined when a shell-tool part finishes. Candidate sites: packages/ui/src/components/message-part.tsx (multiple Switch blocks at L647, L861, L1348, L2110, L2185).
Summary
In composer shell mode (
mod+shift+x), sending any command — including successful ones likegh --helpand nonexistent ones likeabsolutelyfake— triggers a renderer crash:Full stack from the session:
Repro
bun run dev:desktoponorigin/dev(or any branch derived from post-fix: prevent shell failure render crash #174 dev)mod+shift+xto enter shell modegh --help(or any command, succeeding or failing)Relation to #171 / #174
#174 addressed renderer crashes on failed shell commands by replacing Switch with Show inside
packages/ui/src/components/basic-tool.tsx. Manual reverification shows that (a) the crash now also fires on successful commands and (b) it originates from a different<Switch>than the one #174 patched —basic-tool.tsxno longer contains<Switch>in the current tree, so theswitchFunc(...) is not a functionstack must be from another message-part or tool render path.Verified
origin/devworktree (checked at4274751ab9, HEAD at issue filing). Not introduced by feat(app): home redesign per #151 #180;#180does not modifypackages/uior any<Switch>rendering code.Next steps
<Switch>whose<Match when={...}>predicate collapses to undefined when a shell-tool part finishes. Candidate sites:packages/ui/src/components/message-part.tsx(multiple Switch blocks at L647, L861, L1348, L2110, L2185).packages/app/e2e/prompt/prompt-shell.spec.ts) covering both success and failure shell output render.Refs