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.

"Error: Cannot find module 'node:perf_hooks'"

See original GitHub issue

Version 0.14.0 works fine, but every version above throws the error below. I tried to find a solution, but I do not know anything about Node js, etc… The extension was installed/updated using the extension manager from VS Code.

`internal/modules/cjs/loader.js:937 throw err; ^

Error: Cannot find module ‘node:perf_hooks’ Require stack:

  • c:\Users\xxxxx.vscode\extensions\znck.grammarly-0.22.0\dist\server\index.node.js at Function.Module._resolveFilename (internal/modules/cjs/loader.js:934:15) at Module._load (internal/modules/cjs/loader.js:779:27) at Function.f._load (electron/js2c/asar_bundle.js:5:12913) at Module.require (internal/modules/cjs/loader.js:1006:19) at require (internal/modules/cjs/helpers.js:88:18) at c:\Users\xxxxx.vscode\extensions\znck.grammarly-0.22.0\dist\server\index.node.js:38:3661 at c:\Users\xxxxx.vscode\extensions\znck.grammarly-0.22.0\dist\server\index.node.js:2:245 at Object.<anonymous> (c:\Users\xxxxx.vscode\extensions\znck.grammarly-0.22.0\dist\server\index.node.js:64:604) at Module._compile (internal/modules/cjs/loader.js:1125:30) at Object.Module._extensions…js (internal/modules/cjs/loader.js:1155:10) { code: ‘MODULE_NOT_FOUND’, requireStack: [ ‘c:\Users\xxxxx\.vscode\extensions\znck.grammarly-0.22.0\dist\server\index.node.js’ ] } [Error - 14:24:55] Connection to server got closed. Server will not be restarted.`

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:2
  • Comments:12

github_iconTop GitHub Comments

2reactions
jamesonecommented, May 18, 2022

I am on node 16.5 - I had to use the Grammarly version: v0.14.0 <~ this allows you to login to Grammarly too 😃

1reaction
semaphore-eggcommented, Aug 12, 2022

Updating to the latest VS Code version fixed the problem for me.

Can I know what is your last bad version?

Code was not updated since February, but I cant tell yout the exact version number since it’s not displayed anymore.

After updated my vscode to 1.7.0, the errors disappears but the extension (latest, 0.22.1) still do not work. This time the extension seems to crash silently, wired.

Check the output - maybe you didnt sign in to grammarly. Solution for me: F1 -> Grammarly: login

I manually restart the grammerly language server and it seems works. Although some errors are still there. I have updated my opened issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

cannot find module [Node npm Error Solved] - freeCodeCamp
In my case, I got it like this "Module not found: Error: Can't resolve 'react-icons/fa' in 'C:\Users\user\Desktop\Projects\Address Locator\ ...
Read more >
[Node] OpenTelemetry Node.js not working with Node ...
I am using v8.11.4 it is working with openTelemetry and showing no errors. ... I can't find why data is going but not...
Read more >
How do I resolve "Cannot find module" error using Node.js?
Using npm install installs the module into the current directory only (in a subdirectory called node_modules ). Is app.js located under ...
Read more >
[Solution] Error: Cannot Find Module "nodemailer" - Courier
This is a common Nodemailer error -- get the solution for Error: Cannot Find Module "nodemailer".
Read more >
Fix Global Installs Not Working | "Cannot find module" error FIX
Getting " Cannot find module " after installing something globally (with -g)? Well, this video shows you how to fix global package/module ...
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