Desktop report: ReferenceError: Cannot access 'layout' before initialization. #6470

Closed
opened 2026-02-16 18:04:19 -05:00 by yindo · 1 comment
Owner

Originally created by @Eric-Guo on GitHub (Jan 16, 2026).

Originally assigned to: @adamdotdevin on GitHub.

Description

ReferenceError: Cannot access 'layout' before initialization.
@http://localhost:3000/src/pages/layout.tsx:25:46
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
Layout2@http://localhost:3000/src/pages/layout.tsx:25:33
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
@[native code]
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25
provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25
provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25
provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14
runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24
updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17
devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20
children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27
@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34

Plugins

not relative

OpenCode version

dev

Steps to reproduce

  1. Just build the desktop and start touri app

Screenshot and/or share link

No response

Operating System

macOS

Terminal

No response

Originally created by @Eric-Guo on GitHub (Jan 16, 2026). Originally assigned to: @adamdotdevin on GitHub. ### Description ReferenceError: Cannot access 'layout' before initialization. @http://localhost:3000/src/pages/layout.tsx:25:46 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 Layout2@http://localhost:3000/src/pages/layout.tsx:25:33 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 @[native code] untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25 provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25 provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 children@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:606:31 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:43 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createRenderEffect@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:236:25 provider@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1051:23 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1515:26 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 createMemo@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:267:27 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 untrack@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:462:14 runComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:734:24 updateComputation@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:717:17 devComponent@http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:582:20 children@http://localhost:3000/@fs/Users/guochunzhong/git/oss/opencode/packages/ui/src/context/helper.tsx:29:27 @http://localhost:3000/node_modules/.vite/deps/chunk-VL2SL2GY.js:1056:34 ### Plugins not relative ### OpenCode version dev ### Steps to reproduce 1. Just build the desktop and start touri app ### Screenshot and/or share link _No response_ ### Operating System macOS ### Terminal _No response_
yindo added the bugweb labels 2026-02-16 18:04:19 -05:00
yindo closed this issue 2026-02-16 18:04:19 -05:00
Author
Owner

@Eric-Guo commented on GitHub (Jan 16, 2026):

Fix at 704276753b

@Eric-Guo commented on GitHub (Jan 16, 2026): Fix at 704276753ba4a6f1ecd6d3044aefee452914e399
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#6470