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

fs.stat() with options doesn't work #158

Closed
manidlou opened this issue Mar 27, 2019 · 5 comments
Closed

fs.stat() with options doesn't work #158

manidlou opened this issue Mar 27, 2019 · 5 comments

Comments

@manidlou
Copy link

fs.stat() and its relatives accept an additional options object fs.stat(path[, options], callback) since node v10.5.0.

https://nodejs.org/api/fs.html#fs_fs_stat_path_options_callback

seems like graceful-fs hasn't been updated yet! This will cause issues for projects that depend on graceful-fs. I am one of the maintainers of fs-extra and this prevents us from using fs.stat() with bigint option!

@brodycj
Copy link

brodycj commented May 8, 2019

I think this would need minor code fixes in the following places:

I suspect the harder part would be to update the tests test/stats.js, which seems to only test statSync.

@wmertens
Copy link

wmertens commented Jun 6, 2019

same for readdir btw…

@JustinLivi
Copy link

I opened the above issue (jprichardson/node-fs-extra#703) in fs-extra but the issue might lie in this project, I'm not sure.

Even after upgrading both packages I'm inconsistently getting the cb.apply is not a function error.

@isaacs
Copy link
Owner

isaacs commented Jul 2, 2019

@JustinLivi It's likely a result of having two different versions of graceful-fs in play at the same time. What do you see when you run npm ls graceful-fs?

@JustinLivi
Copy link

@isaacs thanks - you were right. I was having a collision between jest and fs-extra. Installing graceful-fs as a direct dependency resolved the issue 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants