We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Function getWslDrivesMountPoint always returns the default mount point '/mnt/'. This is due to that fs.constants.F_OK always triggers the exception:
getWslDrivesMountPoint
'/mnt/'
fs.constants.F_OK
TypeError: Cannot read property 'F_OK' of undefined
According to the documentation of fs, fs.promises does not have constants. So we should probably import constants as well.
fs
fs.promises
constants
The text was updated successfully, but these errors were encountered:
Maybe due to nodejs version. The one I had was node v12.18.2. fs.promises only has the following properties in node v14 as well:
> const { promises } = require("fs"); undefined > promises { access: [AsyncFunction: access], copyFile: [AsyncFunction: copyFile], open: [AsyncFunction: open], opendir: [Function: opendir], rename: [AsyncFunction: rename], truncate: [AsyncFunction: truncate], rmdir: [AsyncFunction: rmdir], mkdir: [AsyncFunction: mkdir], readdir: [AsyncFunction: readdir], readlink: [AsyncFunction: readlink], symlink: [AsyncFunction: symlink], lstat: [AsyncFunction: lstat], stat: [AsyncFunction: stat], link: [AsyncFunction: link], unlink: [AsyncFunction: unlink], chmod: [AsyncFunction: chmod], lchmod: [AsyncFunction: lchmod], lchown: [AsyncFunction: lchown], chown: [AsyncFunction: chown], utimes: [AsyncFunction: utimes], lutimes: [AsyncFunction: lutimes], realpath: [AsyncFunction: realpath], mkdtemp: [AsyncFunction: mkdtemp], writeFile: [AsyncFunction: writeFile], appendFile: [AsyncFunction: appendFile], readFile: [AsyncFunction: readFile] }
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Function
getWslDrivesMountPoint
always returns the default mount point'/mnt/'
. This is due to thatfs.constants.F_OK
always triggers the exception:According to the documentation of
fs
,fs.promises
does not haveconstants
. So we should probably importconstants
as well.The text was updated successfully, but these errors were encountered: