From 3eea1573a6bd1604c9e31ab9a9becd5f938fb427 Mon Sep 17 00:00:00 2001 From: Pawel Kosiec Date: Tue, 10 Nov 2026 19:26:37 +0100 Subject: [PATCH 1/2] fix(template): resolve the template pnpm lock with pnpm 11.1.2 The v0.91.3 template sync failed with ERR_PNPM_MISSING_TIME. With minimumReleaseAge set explicitly, pnpm runs in strict mode, and pnpm 11.0.8 rethrows on abbreviated npm metadata (no per-version time) instead of fetching full metadata. Fixed in pnpm 11.1.2 (pnpm/pnpm#11619, pnpm/pnpm#11622). The sync now runs pnpm@11.1.2 through npx for the template install only, with pm-on-fail=ignore so it doesn't switch to the template's packageManager pin. The template keeps pnpm@11.0.8, which the Apps runtime bundles; 11.1.2 writes the same lockfile and 11.0.8 installs it with --frozen-lockfile. Co-authored-by: Isaac Signed-off-by: Pawel Kosiec --- tools/publish-template-tag.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/tools/publish-template-tag.ts b/tools/publish-template-tag.ts index c778000bf..9d0ae4466 100644 --- a/tools/publish-template-tag.ts +++ b/tools/publish-template-tag.ts @@ -109,8 +109,12 @@ if (npmExit !== 0) { } console.log("✓ template/package-lock.json updated (npm install)"); +// pnpm 11.1.2+ is needed for minimumReleaseAge on public npm (ERR_PNPM_MISSING_TIME, +// pnpm/pnpm#11619); the template itself stays pinned to the Apps runtime's pnpm. +const PNPM = ["--yes", "pnpm@11.1.2"]; + // 2b. pnpm preflight — fail loud rather than silently skip the pnpm lock. -if (run("pnpm", ["--version"]) !== 0) { +if (run("npx", [...PNPM, "--version"]) !== 0) { console.error( "pnpm is not invokable — cannot regenerate template/pnpm-lock.yaml. " + "Ensure the release runner's pnpm setup ran before this script.", @@ -123,9 +127,11 @@ if (run("pnpm", ["--version"]) !== 0) { // pnpm ignores minimumReleaseAge CLI flags; the exclude env var must be a JSON array. const pnpmExit = await runInstallWithRetry( "pnpm install", - "pnpm", - ["install", "--lockfile-only", "--no-frozen-lockfile"], + "npx", + [...PNPM, "install", "--lockfile-only", "--no-frozen-lockfile"], { + // Don't switch to the template's packageManager pin. + pnpm_config_pm_on_fail: "ignore", pnpm_config_minimum_release_age: String(RELEASE_AGE_DAYS * 24 * 60), pnpm_config_minimum_release_age_exclude: JSON.stringify([ RELEASE_AGE_EXCLUDE, From 6f6fa68490d5e1751b970189a48cc779e77afed1 Mon Sep 17 00:00:00 2001 From: Pawel Kosiec Date: Tue, 10 Nov 2026 19:29:24 +0100 Subject: [PATCH 2/2] chore(template): shorten pnpm comment and link the issue Co-authored-by: Isaac Signed-off-by: Pawel Kosiec --- tools/publish-template-tag.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/publish-template-tag.ts b/tools/publish-template-tag.ts index 9d0ae4466..469f1db63 100644 --- a/tools/publish-template-tag.ts +++ b/tools/publish-template-tag.ts @@ -109,8 +109,7 @@ if (npmExit !== 0) { } console.log("✓ template/package-lock.json updated (npm install)"); -// pnpm 11.1.2+ is needed for minimumReleaseAge on public npm (ERR_PNPM_MISSING_TIME, -// pnpm/pnpm#11619); the template itself stays pinned to the Apps runtime's pnpm. +// 11.1.2+ fixes minimumReleaseAge on public npm: https://github.com/pnpm/pnpm/issues/11619 const PNPM = ["--yes", "pnpm@11.1.2"]; // 2b. pnpm preflight — fail loud rather than silently skip the pnpm lock.