-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Install failed with 'sharp_local_prebuilds' #3154
Comments
Hi, the https://sharp.pixelplumbing.com/install#custom-prebuilt-binaries https://github.com/lovell/sharp/releases/tag/v0.30.3 https://github.com/prebuild/prebuild-install#local-prebuilds |
It's my mistake 🤐 I uploaded the libvips and sharp binaries on the company Nexus repository and set the following variables in my .npmrc
Thanks ! it works fine 👍 |
@lovell I am also behind a proxy and unable to download the libvips binaries from github. However, I do not have a server that I can upload them to as a host, like @juliusdev did.
Are there variables that can be set to have the libvips binaries loaded from a local file path? I am hoping there are libvips equivalents of thank you! |
@dirjk sharp will always looks for a globally-installed libvips at |
I'm also stucked on installing sharp behind a proxy on MacOS. I followed this steps
My
npm install fail with this error
|
@ricovitch Please open a new installation issue and answer all of the questions if you still require help. |
Ok sure I'll do that thank you for the fast answer. |
Hello, I was checking it and it was not possible to find a solution with the indicated steps. I created the .npmrc file in my project with the requested content and the error still persists. The truth is, I have done everything and it has not been possible for me to find a solution. sharp_local_prebuilds= C:\Users\Jehico.Bolívar\base-baileys-memory\libvips-8.12.2-win32-x64.tar.br machine specifications npm ERR! code 1 npm ERR! A complete log of this run can be found in: C:\Users\Jehico.Bolívar\AppData\Local\npm-cache_logs\2024-03-06T20_15_26_970Z-debug-0.log |
For anyone coming here, please upgrade to the latest version of sharp, currently v0.33.2, and this entire class of problem goes away (see #3750 for context). |
Hi,
I have an issue with the sharp installation, behind a http proxy which filter access to Github.
According the doc, the fallback is to set the 'sharp_local_prebuilds' npm config or the 'npm_config_sharp_local_prebuilds' env variable before install.
Here my .npmrc file content :
sharp_local_prebuilds=/mnt/d/Dev/Projects/testsharp/libvips-8.12.2-linux-x64.tar.br
I checked the npm config 'sharp_local_prebuilds'
Here my env var :
Now when I trying to install sharp with npm, the script try again to download the lib from github repository and fail.
Possible install-time or require-time problem
npm install
is the same as the architecture and platform of Node.js used at runtime.Are you using the latest version of sharp?
sharp
as reported bynpm view sharp dist-tags.latest
.If you cannot confirm this, please upgrade to the latest version and try again before opening an issue.
If you are using another package which depends on a version of
sharp
that is not the latest, please open an issue against that package instead.Is this a problem with filesystem permissions?
If you are using npm v6 or earlier and installing as a
root
orsudo
user, have you tried with thenpm install --unsafe-perm
flag?If you are using npm v7 or later, does the user running
npm install
own the directory it is run in?If you are using the
ignore-scripts
feature ofnpm
, have you tried with thenpm install --ignore-scripts=false
flag?What is the complete output of running
npm install --verbose sharp
?npm verb enoent
npm WARN testsharp No description
npm WARN testsharp No repository field.
npm WARN testsharp No README data
npm WARN testsharp No license field.
npm verb stack Error: sharp@0.30.3 install:
(node install/libvips && node install/dll-copy && prebuild-install) || (node install/can-compile && node-gyp rebuild && node install/dll-copy)
npm verb stack Exit status 1
npm verb stack at EventEmitter. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
npm verb stack at EventEmitter.emit (events.js:400:28)
npm verb stack at ChildProcess. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
npm verb stack at ChildProcess.emit (events.js:400:28)
npm verb stack at maybeClose (internal/child_process.js:1058:16)
npm verb stack at Process.ChildProcess._handle.onexit (internal/child_process.js:293:5)
npm verb pkgid sharp@0.30.3
npm verb cwd /mnt/d/Dev/Projects/testsharp
npm verb Linux 5.10.16.3-microsoft-standard-WSL2
npm verb argv "/usr/bin/node" "/usr/bin/npm" "i" "--verbose" "sharp"
npm verb node v14.19.0
npm verb npm v6.14.16
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp@0.30.3 install:
(node install/libvips && node install/dll-copy && prebuild-install) || (node install/can-compile && node-gyp rebuild && node install/dll-copy)
npm ERR! Exit status 1
What is the output of running
npx envinfo --binaries --system --npmPackages=sharp --npmGlobalPackages=sharp
?The text was updated successfully, but these errors were encountered: