Fail fast on missing terrain assets and recover empty renders

This commit is contained in:
2026-10-04 22:32:11 +05:00
parent 79d0f53a79
commit 763cf8713c
15 changed files with 842 additions and 21 deletions

View File

@@ -7,6 +7,8 @@ await mkdir(".data", { recursive: true });
await mkdir("public/generated", { recursive: true });
await mkdir("public/tools/mod", { recursive: true });
await mkdir("public/tools/plugin", { recursive: true });
// Prepare terrain assets even if browser installation subsequently fails.
await prepareAssets();
await new Promise((resolve, reject) => {
const p = spawn(
process.execPath,
@@ -19,7 +21,6 @@ await new Promise((resolve, reject) => {
: reject(new Error(`Chromium installation exited ${code}`)),
);
});
await prepareAssets();
process.loadEnvFile(".env.local");
const configured = Boolean(
process.env.NEXT_PUBLIC_SUPABASE_URL &&