From 68f5d1d67d4262c3aa679da1faaf011312434358 Mon Sep 17 00:00:00 2001 From: Mohamed Achaq Date: Fri, 16 Oct 2026 03:27:56 +0000 Subject: [PATCH] fix(desktop): read app.asar entries by native path in the bundle audit The v0.0.69 Windows release failed in the new import check: @electron/asar looks entries up by native path, so "desktop/main/index.mjs" was not found on Windows. Convert to path.sep before extracting. Gate: G0 green; mac bundle audit passes. Co-Authored-By: Claude Opus 5.5 --- scripts/desktop/audit-bundle.mjs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/desktop/audit-bundle.mjs b/scripts/desktop/audit-bundle.mjs index bb83a2f..abfce50 100644 --- a/scripts/desktop/audit-bundle.mjs +++ b/scripts/desktop/audit-bundle.mjs @@ -258,7 +258,9 @@ for (const unpackedAppPath of unpackedAppPaths) { entries: appAsarEntries, main: JSON.parse(extractFile(appAsarPath, "package.json").toString("utf8")) .main, - readFile: (file) => extractFile(appAsarPath, file).toString("utf8"), + // @electron/asar looks entries up by native path (backslashes on Windows). + readFile: (file) => + extractFile(appAsarPath, file.split("/").join(path.sep)).toString("utf8"), }); if (missingAsarImports.length > 0) {