Repository navigation
fix(cli): browser clear reports a browser folder Windows still holds - #6776
Conversation
… EBUSY test covers EPERM
…that fails if it does not
Edit accuracy: accurate 271 (base branch 271), smooth 139 of thoseThe gate passes. Quarantined, measured but not gated (0) Unstable (1)
|
There was a problem hiding this comment.
Verdict: APPROVE · 0 blockers · 0 important · 0 nits · head 3626af06
I confirmed the fails without the fix: claim: with manager.ts set back to main, both does not fail a run when Windows holds a leftover's debug.log cases (EBUSY, EPERM) fail at clearBrowser(). With the fix, manager.test.ts passes 73/73, and oxlint and oxfmt are clean. Only clearBrowser passes false. The pre-download sweep, the forced re-download and the upgrade's set-aside removal keep the default true, so #6771's run-path tolerance is unchanged. Every Actions run at this head passed, including CI, Windows render verification and CodeQL.
What
hyperframes browser clearreports a leftover browser folder that Windows still holds, instead of printing "Removed cached browser" while the folder is still there.Why
#6771 made the shared leftover sweep skip folders Windows holds (
EBUSY/EPERM), so a normal run is never blocked by a running Chrome'sdebug.log.browser cleargoes through the same sweep, so it started swallowing the same error. A user who asks to clear the browser should be told when it did not clear.Related work
Follows #6771, which this is a follow-up to. No other PR touches it.
How
The sweep takes a
tolerateLockedflag, true for the commands that must keep running (download, render) and false forbrowser clear.Test plan
fails without the fix: with
clearBrowserusing the tolerant sweep again,does not fail a run when Windows holds a leftover's debug.logfails for bothEBUSYandEPERM(2 failed, 71 passed).What I measured
manager.test.ts: 73 passed on three runs on Linux; oxfmt and oxlint clean. The test now also coversEPERMand shows the sweep before a download and a forced re-download still resolve whilebrowser clearthrows.What I did NOT execute
A real Windows machine with a running Chrome.