Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(desktop): prevent WSL startup timeout on Windows #6321

Closedchrismin13(GitHub profile, opens in a new tab)wants to merge 5 commits intomain fromrefs/pull/6321/headopened View on GitHub

Showing 4 changed files with 68 additions and 27 deletions (loading 1).

x
0 of 4 viewed, 4 left
9 additions and 8 deletionsapps/desktop/src/backend/DesktopBackendConfiguration.tsModified
View file
@@ -447,8 +447,8 @@
noBrowser: true,
port: input.port,
// Omit t3Home so the Linux backend uses its own home dir instead of
- // the Windows-side baseDir (which would be a /mnt/c path and share
- // the SQLite file with the primary).
+ // the Windows-side baseDir, which would share the primary's SQLite file
+ // through the Windows filesystem mount.
host: wslBindHost,
desktopBootstrapToken: input.bootstrapToken,
// PortSchema rejects 0, so when tailscale serve is disabled we still
@@ -468,9 +468,10 @@
// archive FILE. The Windows primary reads its entry through
// ELECTRON_RUN_AS_NODE (asar-aware), but the WSL backend launches plain
// `wsl.exe -- node`, which can't read inside an asar. electron-builder unpacks
- // the server bundle + node-pty (see asarUnpack in build-desktop-artifact.ts)
- // to the app.asar.unpacked sibling, so point WSL there. In dev appRoot is
- // already a real directory, so this is a no-op.
+ // the server bundle and intentionally external runtime dependencies (see
+ // asarUnpack in build-desktop-artifact.ts) to the app.asar.unpacked sibling,
+ // so point WSL there. In dev appRoot is already a real directory, so this is
+ // a no-op.
const wslAppRoot = environment.isPackaged
? environment.path.join(environment.resourcesPath, "app.asar.unpacked")
: environment.appRoot;
@@ -522,9 +523,9 @@
​
// Build an explicit copy of process.env minus T3CODE_HOME (dev-runner