pnpm run clean fails out of the box on 0.1.7-rc.2: clean.ts rejects the desktop-keyboard-tests tsconfig outDir #7970
Unanswered
HaipingShi
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
pnpm run cleanfails out of the box on 0.1.7-rc.2TL;DR
On a clean checkout of current master (
dsh-v0.1.7-rc.2),pnpm run cleanexits 1 before deleting anything:The new
tsconfig.desktop-keyboard-tests.jsondeclares"outDir": "lib/desktop-keyboard-test-types", andscripts/clean.tsonly accepts outDirs whose basename istypes(plus one special-cased native entry), so plan-time validation throws and the tool never reaches deletion.Why it matters
This is the recovery command that several threads prescribe for the class of failure where a version switch over a long-lived checkout leaves stale
lib/output that breaks the typert/tool layer — #7086 documents exactly that symptom and the standardpnpm run clean → pnpm install → pnpm run buildprocedure. Withcleanitself broken, that procedure is currently not executable; the only workaround is removinglib/directories and*.tsbuildinfofiles by hand.Root cause
tsconfig.desktop-keyboard-tests.jsonwas added in6a82709a2b("fix(shortcuts): preserve focus and tab layout, block overlay input", 09-22) withoutDir: lib/desktop-keyboard-test-types.tsconfig.json→tsconfig.client.json(reference at its line 46) →tsconfig.desktop-keyboard-tests.json, so the file is reachable from the graphRepositoryCleaner.buildOutputDirectories()walks.basename(...) === 'types'or thenative/system/packages/entry/libexception;desktop-keyboard-test-typesmatches neither, so it throws before any target is collected.Verified against current upstream master:
scripts/clean.tsand the tsconfig are byte-identical in my tree, so this is not a fork artifact.Suggested fixes
Either of:
/types(e.g.lib/desktop-keyboard-tests/types), keeping the clean.ts rule as-is; orbuildOutputDirectories()with this outDir as an explicit exception, the waynativeEntryOutputalready is.Happy to send the one-liner for either direction if maintainers say which they prefer.
All reactions