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.

Windows - Specified module not found: Sharp

See original GitHub issue

Additional information here: https://github.com/lovell/sharp/issues/1387

I have also tried making a brand new project with sharp as the only package. index.js

const testMod = require("sharp");

console.log("Done!");

package.json

{
  "dependencies": {
    "sharp": "^0.20.8"
  }
}

Running gives me this error:

internal/modules/cjs/loader.js:718
  return process.dlopen(module, path.toNamespacedPath(filename));
                 ^

Error: The specified module could not be found.
\\?\E:\Computer-Stuff\Javascript\2018\New folder\node_modules\sharp\build\Release\sharp.node
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:718:18)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)
    at Module.require (internal/modules/cjs/loader.js:637:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous> (E:\Computer-Stuff\Javascript\2018\New folder\node_modules\sharp\lib\constructor.js:10:15)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
    at Module.load (internal/modules/cjs/loader.js:599:32)
PS E:\Computer-Stuff\Javascript\2018\New folder>

What I have done: I have installed node-gyp, I have installed windows-build-tools 6 times and redid install for vs community twice and installed python 2.7 twice. But nothing works. I have been stuck on this problem for at least a week and I’m am really frustrated.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:16 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
lovellcommented, Sep 26, 2018

Great, thanks for confirming.

It looks like there were (temporary) networking problems during a previous installation attempt that corrupted the cache. This situation came up a few days ago in #1382 so I’ll see what can be done to improve error reporting in sharp.

2reactions
lovellcommented, Sep 26, 2018

The salient error this time is:

info sharp Using cached C:\Users\Super\AppData\Roaming\npm-cache\_libvips\libvips-8.6.1-win32-x64.tar.gz
(node:7996) UnhandledPromiseRejectionWarning: ZlibError: zlib: unexpected end of file

Remove the C:\Users\Super\AppData\Roaming\npm-cache\_libvips directory and try again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can't install sharp on windows 10 (x64) - node.js
I'm trying to use node.js sharp to image processing on Windows 10, but require sharp- ...
Read more >
Error: Could not load file or assembly 'CelSharp.Core.dll' or ...
Symptom: When logging into Act! the following error occurs: "Could not load file or assembly 'CelSharp.Core.dll' or one of its dependencies.
Read more >
Polling Build Job SharpSvn.dll - Visual Studio Feedback
The specified module could not be found. File name: 'SharpSvn.dll' at Microsoft.TeamFoundation.Build2.Server.Extensions.SvnConnector.
Read more >
Something went wrong installing the "sharp" module (fix)
There could be many reasons you get this error, as you'll find out when searching on GitHub and StackOverflow. I've tried every solution...
Read more >
Specified module could not be found Windows 10 - YouTube
specifiedmodulecouldnotbefound #directxerror #dllerrorFix specified module could not be found windows 10 error while installing directx or ...
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