chore(ci): update pnpm version, add offline build support to wasm fetch, fix electron coverage

This commit is contained in:
Ivan 2026-05-18 05:10:53 -05:00
parent 72fd3b71e8
commit 3f0baacf10
No known key found for this signature in database
GPG key ID: B84314E2D9332AE0
3 changed files with 15 additions and 3 deletions

View file

@ -6,7 +6,7 @@ set -euo pipefail
cd /src
export UV_VERSION="${UV_VERSION:-0.11.12}"
export PNPM_VERSION="${PNPM_VERSION:-10.33.0}"
export PNPM_VERSION="${PNPM_VERSION:-11.1.2}"
apt-get update -y
apt-get install -y --no-install-recommends \

View file

@ -146,7 +146,19 @@ async function main() {
}
const root = micronWasmRepoRoot();
const { dir, wasm, wasmExec } = micronWasmVendorPaths(root);
const { wasm, wasmExec } = micronWasmVendorPaths(root);
if (process.env.MESHCHATX_OFFLINE_BUILD === "1") {
if (!fs.existsSync(wasm) || !fs.existsSync(wasmExec)) {
console.error(
"fetch-micron-wasm: MESHCHATX_OFFLINE_BUILD=1 but micron-parser-go.wasm or wasm_exec.js is missing."
);
process.exit(1);
}
console.log("fetch-micron-wasm: MESHCHATX_OFFLINE_BUILD=1 and artifacts present, skipping fetch.");
process.exit(0);
}
const { dir } = micronWasmVendorPaths(root);
const wasmUrl = process.env.MICRON_PARSER_GO_WASM_URL || DEFAULT_WASM_URL;
const execUrl = process.env.MICRON_GO_WASM_EXEC_URL || DEFAULT_WASM_EXEC_URL;
const integrityPath = path.join(dir, "integrity.json");

View file

@ -10,7 +10,7 @@ export default defineConfig({
reporter: ["text", "json-summary"],
reportsDirectory: "./coverage-electron",
include: ["electron/**/*.js"],
exclude: ["electron/assets/**", "electron/main-legacy.js"],
exclude: ["electron/assets/**"],
},
},
});