DeepSeek Harness Tauri 桌面版 | Only 8mb installer, zero environment setup, preset plugins, Windows / macOS / Linux.
fix(core): 原生模块探测纳入目录链接形式的包
hairyf66cb1f5286d9
diff --git a/src-tauri/src/service/core/runtime.rs b/src-tauri/src/service/core/runtime.rsindex 1a3c26ca..f508d04d 100644--- a/src-tauri/src/service/core/runtime.rs+++ b/src-tauri/src/service/core/runtime.rs@@ -67,13 +67,16 @@ try {}};if (existsSync(nodeModules)) {+ // 目录链接(pnpm 布局 / 桌面端为插件建立的 junction)在 withFileTypes 下是+ // symbolic link 而非 directory,必须一并纳入,否则会漏掉链接形式的原生包。+ const isPackageDir = (entry) => entry.isDirectory() || entry.isSymbolicLink();for (const entry of readdirSync(nodeModules, { withFileTypes: true })) {- if (!entry.isDirectory()) continue;+ if (!isPackageDir(entry)) continue;if (entry.name === '.bin' || entry.name === '.pnpm') continue;if (entry.name.startsWith('@')) {const scope = join(nodeModules, entry.name);for (const inner of readdirSync(scope, { withFileTypes: true })) {- if (inner.isDirectory()) collect(join(scope, inner.name), entry.name + '/' + inner.name);+ if (isPackageDir(inner)) collect(join(scope, inner.name), entry.name + '/' + inner.name);}continue;}