diff --git a/electron/main/init.ts b/electron/main/init.ts index 66d1738c..5602dc1c 100644 --- a/electron/main/init.ts +++ b/electron/main/init.ts @@ -161,8 +161,8 @@ export async function startBackend( port = await findAvailablePort(5001); fs.writeFileSync(portFile, port.toString()); log.info(`Found available port: ${port}`); - } catch (_error) { - log.error('Failed to find available port, attempting cleanup...'); + } catch (error) { + log.error('Failed to find available port, attempting cleanup...', error); // Last resort: try to kill all processes in the range for (let p = 5001; p <= 5050; p++) { diff --git a/electron/main/install-deps.ts b/electron/main/install-deps.ts index 5cd4a8cb..21e1b489 100644 --- a/electron/main/install-deps.ts +++ b/electron/main/install-deps.ts @@ -18,7 +18,6 @@ import log from 'electron-log'; import fs from 'node:fs'; import os from 'node:os'; import path from 'node:path'; -import { getMainWindow } from './init'; import { cleanupOldVenvs, getBackendPath, @@ -342,7 +341,6 @@ export async function installCommandTool(): Promise { } let uv_path: string; -const _mainWindow = getMainWindow(); const backendPath = getBackendPath(); // Ensure backend directory exists diff --git a/tsconfig.json b/tsconfig.json index 2de55eb9..9d35e6d0 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -20,6 +20,6 @@ "@/*": ["src/*"] } }, - "include": ["src", "electron", "resources/script", "test"], + "include": ["src", "electron", "resources/scripts", "test"], "references": [{ "path": "./tsconfig.node.json" }] }