Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Silence fs.stat() permissions errors #13

Closed
BD103 opened this issue Dec 31, 2024 · 0 comments
Closed

Silence fs.stat() permissions errors #13

BD103 opened this issue Dec 31, 2024 · 0 comments
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@BD103
Copy link
Owner

BD103 commented Dec 31, 2024

This action uses fs.stat() to find information about files in the target directory that may be purged:

fs.stat(filePath).then(async (stat) => {

As reported in nodejs/node#35853, there is an bug where fs.stat() can fail due to lack of permissions on Windows (when it shouldn't). We ran into this issue in this run for bevy-cli.

A lack of permissions shouldn't cause the entire job to fail. cargo-sweep operates on a best-effort basis, and should just skip the file without permissions instead of erroring.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant