| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
cc @nodejs/fs |
Sorry, something went wrong.
Sorry, something went wrong.
|
Test is failing on Windows CI: not ok 520 parallel/test-rmdirSync-busy-loop-windows
---
duration_ms: 0.167
severity: fail
exitcode: 1
stack: |-
node:assert:119
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Missing expected exception.
at Object.<anonymous> (C:\workspace\node-test-binary-windows-js-suites\node\test\parallel\test-rmdirSync-busy-loop-windows.js:25:8)
at Module._compile (node:internal/modules/cjs/loader:1108:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1137:10)
at Module.load (node:internal/modules/cjs/loader:973:32)
at Function.Module._load (node:internal/modules/cjs/loader:813:14)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:76:12)
at node:internal/main/run_main_module:17:47 {
generatedMessage: false,
code: 'ERR_ASSERTION',
actual: undefined,
expected: /EACCES/,
operator: 'throws'
}
|
Sorry, something went wrong.
There was a problem hiding this comment.
Stripping access permissions appears to have broken our Windows CI on the host the test ran on as subsequent jobs are unable to clean the workspace (as the user doesn't have permissions to remove this directory): nodejs/build#2526
Sorry, something went wrong.
There was a problem hiding this comment.
Ah yes, that makes sense. tmpdir.refresh() uses the rimraf code that's fixed here, and there's not usually a reason for tests to clean up their temp directories. I guess the problem could be solved by having this test do a tmpdir.refresh() before exiting. And if we forget to ever remove that workaround, it's not a big deal.
Sorry, something went wrong.
There was a problem hiding this comment.
Is tmpdir.refresh() able to remove a directory where write permissions have been removed?
Sorry, something went wrong.
There was a problem hiding this comment.
I tried it locally and it does not seem to remove the directory. I think I'll have to change the permission before exiting.
Sorry, something went wrong.
There was a problem hiding this comment.
I have updated the code to change the permission for the directory to 0o777 before removing it and I don't see any temporary directories after this is run locally. PTAL.
Sorry, something went wrong.
There was a problem hiding this comment.
If the earlier assertion fails (e.g. as in #36815 (comment)) then the reset of the permissions won't occur?
Sorry, something went wrong.
There was a problem hiding this comment.
No, it does not reset the permissions.
Sorry, something went wrong.
Sorry, something went wrong.
There was a problem hiding this comment.
@richardlau This does reset the permissions regardless of the assertion.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
If the same issue exists with rm, I'd say yes, you should that instead.
So the issue is that Windows doesn't throw a EACCES error (or any error), and you'd expect it to throw because of the previous fs.chmod call, correct? Shouldn't you expect a EPERM error every time? I don't have a Windows machine to investigate very deeply, sorry. |
Sorry, something went wrong.
Sure, I'll do that.
Correct.
Oddly enough, Windows doesn't throw any of them. |
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Fixes: #34580