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

Older Node 18 versions do not provide a constants export #341

Open
mkilpatrick opened this issue Apr 1, 2024 · 3 comments
Open

Older Node 18 versions do not provide a constants export #341

mkilpatrick opened this issue Apr 1, 2024 · 3 comments

Comments

@mkilpatrick
Copy link

Using Node 18.0.0 results in this error after upgrading from 9.x to 10.x.

import fs, {constants as fsConstants} from 'node:fs/promises';
            ^^^^^^^^^
SyntaxError: The requested module 'node:fs/promises' does not provide an export named 'constants'

It's an error until you use >= v18.4.0

@wujingquan
Copy link

i got same problem in node v14, but node v16 and v18 no problem

@luckfunc
Copy link

luckfunc commented Sep 8, 2024

node14x: image

node18: image

@kadinwu
Copy link

kadinwu commented Sep 13, 2024

are you going to merge @luckfunc fix? i meet the same issue with Nodejs14 and upgrade nodejs is not easy.
Could you help fix it in priority? Thanks.

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

4 participants