-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
Error after upgrading to Node 16.6.0 when using ES modules #11708
Comments
Thanks for posting clear steps to reproduce and a repo link, @adalinesimonian I just tested and can confirm what you are seeing. The "ESM mode" of Jest (activated when you for example set If you'd have the time to dig deeper and try to find out what might be causing this particular error, I'm sure the help would be appreciated =) |
The error happens in this part of Node's internal code ( Going up the stack, this is the line in
|
I verified the change in behaviour with an even simpler test case.
In Node.js 16.5.0 and prior, the error given is:
However, in 16.6.0 it is:
There is most certainly a regression in 16.6.0. I'll report this on the Node repository and link this issue. |
Reported in nodejs/node#39618 |
Fix landed in nodejs/node#39593 — however, it is unclear to me when the release containing this fix will come out. Hopefully soon. |
Good job tracing it down nonetheless, @adalinesimonian 🙌 |
No problem, happy to help. Should I keep this issue open until the fix is released or close it now? |
Looks like they are preparing to release tomorrow as it apparently had quite widespread impact. So I'd just leave it open until then |
Verified issue is fixed with Node.js 16.6.1. Closing issue! |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
🐛 Bug Report
Calling jest gives the error:
To Reproduce
Steps to reproduce the behavior:
"type": "module"
in package.json) and install jest ^27.0.6npx jest
,yarn jest
, etc.)Expected behavior
Jest runs without errors.
Link to repl or repo (highly encouraged)
https://github.com/adalinesimonian/node-jest-16.6-error-repro
envinfo
The text was updated successfully, but these errors were encountered: