8

Getting below error for return process.dlopen(module, path._makeLong(filename))

module.js:597
  return process.dlopen(module, path._makeLong(filename));
                 ^

Error: The specified procedure could not be found.
\\?\C:\SLIM_WORKSPACE\slim\slim-web\node_modules\gulp-sass\node_modules\node-sass\vendor\win32-x64\binding.node
    at Error (native)
    at Object.Module._extensions..node (module.js:597:18)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (C:\SLIM_WORKSPACE\slim\slim-web\node_modules\gulp-sass\node_modules\node-sass\lib\index.js:211:15)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
kgangadhar
  • 4,886
  • 5
  • 36
  • 54
  • 1
    I am using windows machine and I have installed required Visual C++ libraries. I applied npm update. but did not worked. –  Sep 25 '17 at 06:10
  • 1
    I used npm rebuild now, but problem still exists. –  Sep 25 '17 at 06:42

3 Answers3

31

I know am a bit late but this worked for me.

Issue these commands to help you remove/delete your project modules and then update them

$rm -rf node_modules/
$npm update
JustBaron
  • 2,319
  • 7
  • 25
  • 37
Moses
  • 635
  • 8
  • 22
  • 2
    Unfortunately this hasn't fixed my issue – Dallas Clark Mar 11 '18 at 01:14
  • 1
    You cannot just update the dependencies version in an organisation. It is better to ask for the correct npm and node version your peers are using to work on the same project. Then remove the node_modules and package-lock.json and run npm install. – Saket Suraj Feb 02 '22 at 05:57
1

You only need to update your node and npm packages in the latest version.

$nvm install --lts    // For install Node latest version 
$npm update          // For update all NPM packages in latest version

$nvm alias default **versionName** // For steup node default version of your PC or server```
  • 1
    This probably won't fix the issue - the error has something to do with a `.dll` not being found, a npm update might fix it if it recompiles that certain library. Please note you need nvm to update node with nvm. Also, this question is about 2,5 years old, I'm unsure if this issue is still at play. Lastly: welcome to stack :) – Roboroads Mar 03 '20 at 09:07
  • This is an npm package issue. These types of errors occurring when an npm package does not work according to the node version. The batter way to solve this, update the node and npm package to the latest version. This will definitely work for everyone. Yes, my answer is too late but it will help other developers who are still facing the same issue. – Rajneshwar Singh Mar 03 '20 at 10:50
  • 1
    Hey Guys, I am seeing this issue. I have tried all the steps above: internal/modules/cjs/loader.js:1025 return process.dlopen(module, path.toNamespacedPath(filename)); ^ Error: Module did not self-register. at Object.Module._extensions..node (internal/modules/cjs/loader.js:1025:18) – user2801184 Jul 09 '20 at 15:16
1

Delete node_modules folder and reinstall dependencies as administrator with npm install

Frank
  • 403
  • 3
  • 10