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

Workaround for node 18 support #404

Merged
merged 2 commits into from
May 22, 2022
Merged

Workaround for node 18 support #404

merged 2 commits into from
May 22, 2022

Conversation

skovhus
Copy link
Collaborator

@skovhus skovhus commented May 22, 2022

I've looked into the issue behind #353 and the node.js support for fetch conflicts with some of the wasm code generated by emscripten – a downstream fix is here and issue here.

I've validated this by disabling fetch using --no-experimental-fetch when running test:

node --no-experimental-fetch  node_modules/.bin/jest server/src/__tests__/server.test.ts

This PR patches the node global environment to work around this. This should be safe as only the language server should be running in the same process.

@codecov
Copy link

codecov bot commented May 22, 2022

Codecov Report

Merging #404 (9b08bcc) into master (9a62f73) will decrease coverage by 0.18%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##           master     #404      +/-   ##
==========================================
- Coverage   74.58%   74.39%   -0.19%     
==========================================
  Files          19       19              
  Lines         657      660       +3     
  Branches      115      116       +1     
==========================================
+ Hits          490      491       +1     
- Misses        151      153       +2     
  Partials       16       16              
Impacted Files Coverage Δ
server/src/parser.ts 80.00% <33.33%> (-20.00%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0ae47b5...9b08bcc. Read the comment docs.

@skovhus skovhus changed the title Add workaround for node 18 support Workaround for node 18 support May 22, 2022
@skovhus skovhus merged commit 02c933d into master May 22, 2022
@skovhus skovhus deleted the ks/node-18 branch May 22, 2022 08:45
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.

1 participant