Repository navigation
[Desktop] Complete Linux Desktop (.deb) Port & Fix for Electron ASAR LibreOfficeKit Fallback #10320
allannuwamanya
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Summary
We have successfully ported and packaged the DeepSeek Harness Electron Desktop application for Linux as a standard
.debinstaller (tested on Ubuntu / Debian x86_64).During this process, we identified and resolved the root-cause bug that previously prevented Linux packaging smoke tests from completing.
Root Cause Analysis: The Electron ASAR
lstatSyncFallback BugWhen packaging the desktop application,
apps/desktop/scripts/smoke-packaged-runtime.tsvalidates headless document conversion via LibreOfficeKit:@deepseek-ai/libreoffice-kit,resolveEngine()probes for native engine@deepseek-ai/libreoffice-kit-linux-x64-glibc.require.resolve()throwsMODULE_NOT_FOUND.lib/index.js:1530), it checks whether the package was installed but incomplete:app.asar), Electron's ASAR filesystem wrapper forfs.lstatSync(path, { throwIfNoEntry: false })returnsnullinstead of Node's nativeundefinedwhen querying missing paths inside the archive.null !== void 0evaluates totrue.@deepseek-ai/libreoffice-kit-wasm.The Solution
In
apps/desktop-host/src/office-engine.ts, we installed an ESMregisterHooksresolution hook that interceptsnode:fscalls originating from@deepseek-ai/libreoffice-kit:This normalizes
nullreturns toundefinedin strict accordance with Node's API specification, allowing LibreOfficeKit to smoothly fall back to@deepseek-ai/libreoffice-kit-wasmon Linux. All DOCX, XLSX, and PPTX conversions pass the packaged smoke tests.Direct Download & Working Repository
.debDownload: deepseek-harness-0.2.1-rc.2-linux-amd64-unsigned.debVerified Running on Linux
The application boots, connects to the local Node host backend, and successfully runs full chat and tool execution sessions on Linux.
We hope this diagnosis and patch are helpful for the team when incorporating official Linux desktop builds!
All reactions