fix(build): stop the runtime install stamp from staling web/desktop

Install/update completion rewrites the root install-stamp.json (fresh
builtAt) after products are built, and the stamp was still a shared
web/desktop source input, so every install left its own web_dist
"missing, stale, or damaged" and the post-install probe failed on every
installer E2E leg. Nothing in either build reads the root stamp;
desktop's baked stamp is already tracked as a prepared input.
This commit is contained in:
ethernet
2026-09-23 15:50:58 -04:00
parent 6cbd72cec1
commit b3618bda35
2 changed files with 6 additions and 1 deletions

View File

@@ -44,7 +44,9 @@ export function sourceHash(source, product) {
workspace, 'apps/shared', 'package.json', 'package-lock.json', '.npmrc', 'pm/lock.json',
'scripts/build',
'scripts/generate-icons.mjs', 'scripts/generate_icons.py',
'assets', 'pyproject.toml', 'uv.lock', 'install-stamp.json',
// The root install-stamp.json is runtime identity rewritten after every install; desktop's
// baked stamp is a prepared input.
'assets', 'pyproject.toml', 'uv.lock',
], name => {
// Build scripts are inputs; workspace build directories are outputs.
const parts = name.split('/')

View File

@@ -237,6 +237,9 @@ test('built web freshness follows shared sources and build inputs, not mtimes or
expect(productCurrent({ source, product: 'web', out })).toBe(true)
put(source, 'web/node_modules/.tmp/tsbuildinfo', 'generated')
expect(productCurrent({ source, product: 'web', out })).toBe(true)
// Install completion rewrites the runtime identity after building products.
put(source, 'install-stamp.json', '{"builtAt": "later"}')
expect(productCurrent({ source, product: 'web', out })).toBe(true)
put(icons, 'web/public/favicon.ico', 'changed prepared icon')
expect(productCurrent({ source, product: 'web', out })).toBe(false)
await buildWeb({ source, icons, out })