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

Support node 14 #758

Merged
merged 3 commits into from
Apr 13, 2021
Merged

Support node 14 #758

merged 3 commits into from
Apr 13, 2021

Conversation

eivisand
Copy link
Contributor

@eivisand eivisand commented Nov 3, 2020

Summary

Solves Module.createRequireFromPath() is deprecated
Node 14 has made it to long term support, and it crashes when used with Haul. To fix this I've bumped @types/node to currtent, and added Module.createRequire with fallback to Module.createRequireFromPath where only Module.createRequireFromPath was used before.
In addition I fixed type errors that came with the @types/node update.

Test plan

I'm not sure how best to test, I ran the jest tests locally, and failed 7 test suites, 10 tests, and 3 snapshots on the PR branch vs 10 test suites, 15 tests and 3 snapshots on master. Looks like createRequireFromPath and createRequire are equivalent api equivalent, apart from createRequire supporting URL input, so they should be swappable.

@eivisand
Copy link
Contributor Author

Pinging this, would be nice with a review 🌝

@tido64
Copy link
Contributor

tido64 commented Apr 13, 2021

@zamotany, @thymikee: Is this something you could take a look at?

Copy link
Member

@thymikee thymikee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zamotany please take a look and merge if ready

@zamotany zamotany merged commit c180130 into callstack:master Apr 13, 2021
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

Successfully merging this pull request may close these issues.

None yet

4 participants