question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Breaking change on older node versions

See original GitHub issue

🐛 Bug Report

I am currently using nodejs v9.5 and getting error on new client version v7.7.0 that has been released hours ago. I don’t know if it is done intentionally or not(Sorry if it is done intentionally). But seems like older node versions does not work with the following declaration of generator functions:

async * FunctionName(){}

giving me error on lib/Helpers.js on line 56:

  async * scrollSearch (params, options = {}) {
        ^

To Reproduce

Running on an older version on node reproduces the error. Adding the error screenshot 22

Your Environment

  • node version: 9.5
  • @elastic/elasticsearch version: >=7.7.0
  • os: Mac

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:3
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
peshrawahmedcommented, Nov 5, 2021

Hey! Still facing this issue. Although I’ve updated node.js version, I also tried multiple LTS versions of node.js to go with but the error persists. Using node.js version v16.13.0 and elasticsearch client version 7.13.0 and elasticsearch version 7.10 OS Ubuntu Please help out as soon as possible.

May sound silly but can you remove node_modules and package-lock files and run npm i again.

and also can you run node -v to double check if you are using the right version.

2reactions
delvedorcommented, Jun 8, 2021

Hello! Plase take a look at out Node.js support table, both Node v8 and v10 are no longer supported. I would also strongly recommend migrating to a supported version of Node.js, as using an unsupported version could expose you to severe security risks. You can find the officially supported versions of Node.js here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Breaking changes from V10 -> V16 ? #42622 - GitHub
There are many breaking changes between Node.js 10 to 16. To find them in the changelog, you'd need to review the semver major...
Read more >
What is a sustainable method to upgrading node from old ...
What is the approach I should take in upgrading them to the latest Node version without breaking existing functionality?
Read more >
Everything about the latest Node.js release | Node.js 16
npm v7 has quite a few breaking changes from previous versions, including new version of package-lock.json as well as several other significant ...
Read more >
Can I change the version of node.js my project uses?
Yes, you can do so by updating the engines field specified in the package.json project file. Currently, Glitch supports node.js versions 6.17.1 through ......
Read more >
Node.js 18 - What Changes Does It Bring, And How Will They ...
The development team of the popular tool will support it until 2025. Should you migrate onto version 18 now, you will have three...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found