Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Windows: The specified procedure could not be found, with canvas as dependency #2311

Closed
CaiIsProgrammer opened this issue Aug 3, 2020 · 6 comments

Comments

@CaiIsProgrammer
Copy link

Did you see the documentation relating to installation?
yes

Have you ensured the platform and version of Node.js used for npm install is the same as the platform and version of Node.js used at runtime?
yes

Are you using the latest version? Is the version currently in use as reported by npm ls sharp the same as the latest version as reported by npm view sharp dist-tags.latest?
yes

If you are installing as a root or sudo user, have you tried with the npm install --unsafe-perm flag?
yes

If you are using the ignore-scripts feature of npm, have you tried with the npm install --ignore-scripts=false flag?
yes

What is the complete output of running npm install --verbose sharp? Have you checked this output for useful error messages?
yes and no useful error messages

`C:\Users\cmart\Documents\tcg\tcgbe>npm install --verbose sharp
npm info it worked if it ends with ok
npm verb cli [
npm verb cli 'C:\Program Files\nodejs\node.exe',
npm verb cli 'C:\Users\cmart\AppData\Roaming\npm\node_modules\npm\bin\npm-cli.js',
npm verb cli 'install',
npm verb cli '--verbose',
npm verb cli 'sharp'
npm verb cli ]
npm info using npm@6.14.7
npm info using node@v12.18.3
npm verb npm-session 31b6913a2d51b159
npm http fetch GET 200 https://registry.npmjs.org/sharp 230ms
npm timing stage:loadCurrentTree Completed in 1590ms
npm timing stage:loadIdealTree:cloneCurrentTree Completed in 14ms
npm timing stage:loadIdealTree:loadShrinkwrap Completed in 692ms
npm http fetch GET 304 https://registry.npmjs.org/node-addon-api 72ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/color 133ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/prebuild-install 157ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/simple-get 162ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/color-convert 52ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/color-string 55ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/color-name 49ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/simple-swizzle 48ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/is-arrayish 47ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/which-pm-runs 60ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/node-abi 66ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/expand-template 72ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/noop-logger 76ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/napi-build-utils 118ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/github-from-package 132ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/tar-fs 135ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/semver 48ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/mkdirp-classic 61ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/tar-stream 66ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/bl 53ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/readable-stream 57ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/inherits 55ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/decompress-response 43ms (from cache)
npm http fetch GET 304 https://registry.npmjs.org/mimic-response 48ms (from cache)
npm timing stage:loadIdealTree:loadAllDepsIntoIdealTree Completed in 1787ms
npm timing stage:loadIdealTree Completed in 2737ms
npm timing stage:generateActionsToTake Completed in 73ms
npm verb correctMkdir C:\Users\cmart\AppData\Roaming\npm-cache_locks correctMkdir not in flight; initializing
npm verb makeCacheDir UID & GID are irrelevant on win32
npm verb lock using C:\Users\cmart\AppData\Roaming\npm-cache_locks\staging-7144923832d567b6.lock for C:\Users\cmart\Documents\tcg\tcgbe\node_modules.staging
npm timing action:extract Completed in 46ms
npm info lifecycle sharp@0.25.4preuninstall: sharp@0.25.4
npm info lifecycle sharp@0.25.4
uninstall: sharp@0.25.4
npm verb unbuild rmStuff sharp@0.25.4 from C:\Users\cmart\Documents\tcg\tcgbe\node_modules
npm info lifecycle sharp@0.25.4postuninstall: sharp@0.25.4
npm timing action:unbuild Completed in 3ms
npm timing action:remove Completed in 142ms
npm timing action:finalize Completed in 2ms
npm timing action:refresh-package-json Completed in 12ms
npm info lifecycle sharp@0.25.4
preinstall: sharp@0.25.4
npm timing action:preinstall Completed in 0ms
npm info linkStuff sharp@0.25.4
npm timing action:build Completed in 1ms
npm info lifecycle sharp@0.25.4~install: sharp@0.25.4

sharp@0.25.4 install C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp
(node install/libvips && node install/dll-copy && prebuild-install --runtime=napi) || (node-gyp rebuild && node install/dll-copy)

info sharp Using cached C:\Users\cmart\AppData\Roaming\npm-cache_libvips\libvips-8.9.1-win32-x64.tar.gz
info sharp Creating C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\build\Release
info sharp Copying DLLs from C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\vendor\lib to C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\build\Release
prebuild-install info begin Prebuild-install version 5.3.5
prebuild-install info looking for cached prebuild @ C:\Users\cmart\AppData\Roaming\npm-cache_prebuilds\b07804-sharp-v0.25.4-napi-v3-win32-x64.tar.gz
prebuild-install info found cached prebuild
prebuild-install info unpacking @ C:\Users\cmart\AppData\Roaming\npm-cache_prebuilds\b07804-sharp-v0.25.4-napi-v3-win32-x64.tar.gz
prebuild-install info unpack resolved to C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\build\Release\sharp.node
prebuild-install info install Successfully installed prebuilt binary!
npm verb lifecycle sharp@0.25.4install: unsafe-perm in lifecycle true
npm verb lifecycle sharp@0.25.4
install: PATH: C:\Users\cmart\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\node_modules.bin;C:\Users\cmart\Documents\tcg\tcgbe\node_modules.bin;C:\Python38\Scripts;C:\Python38;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Windows\System32\OpenSSH;C:\Program Files\PuTTY;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Git\cmd;C:\Program Files\nodejs;C:\ProgramData\chocolatey\bin;C:\Users\cmart\AppData\Local\Microsoft\WindowsApps;C:\Users\cmart\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\cmart\AppData\Roaming\npm
npm verb lifecycle sharp@0.25.4install: CWD: C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp
npm timing audit submit Completed in 261ms
npm http fetch POST 200 https://registry.npmjs.org/-/npm/v1/security/audits/quick 261ms
npm timing audit body Completed in 0ms
npm timing action:install Completed in 1513ms
npm info lifecycle sharp@0.25.4
postinstall: sharp@0.25.4
npm timing action:postinstall Completed in 1ms
npm verb unlock done using C:\Users\cmart\AppData\Roaming\npm-cache_locks\staging-7144923832d567b6.lock for C:\Users\cmart\Documents\tcg\tcgbe\node_modules.staging
npm timing stage:executeActions Completed in 1742ms
npm timing stage:rollbackFailedOptional Completed in 0ms
npm timing stage:runTopLevelLifecycles Completed in 6366ms
npm verb saving [ { name: 'sharp', spec: '^0.25.4', save: 'dependencies' } ]
npm verb shrinkwrap skipping write for package.json because there were no changes.
npm info lifecycle undefinedpreshrinkwrap: undefined
npm info lifecycle TcgBackEnd@1.0.0
shrinkwrap: TcgBackEnd@1.0.0
npm verb shrinkwrap skipping write for package-lock.json because there were no changes.
npm info lifecycle TcgBackEnd@1.0.0~postshrinkwrap: TcgBackEnd@1.0.0
npm WARN TcgBackEnd@1.0.0 No description
npm WARN TcgBackEnd@1.0.0 No repository field.

  • sharp@0.25.4
    updated 1 package and audited 996 packages in 6.817s

30 packages are looking for funding
run npm fund for details

found 0 vulnerabilities

npm verb exit [ 0, true ]
npm timing npm Completed in 7670ms
npm info ok`

What is the output of running npx envinfo --binaries --system?

C:\Users\cmart\Documents\tcg\tcgbe>npx envinfo --binaries --system
npx: installed 1 in 1.66s

System:
OS: Windows 10 10.0.19041
CPU: (16) x64 AMD Ryzen 7 2700 Eight-Core Processor
Memory: 7.20 GB / 15.95 GB
Binaries:
Node: 12.18.3 - C:\Program Files\nodejs\node.EXE
npm: 6.14.7 - C:\Program Files\nodejs\npm.CMD

@lovell
Copy link
Owner

lovell commented Aug 4, 2020

Does the repo at C:\Users\cmart\Documents\tcg\tcgbe also have node-canvas as a dependency? If so, please see #2125 specifically #2125 (comment)

@CaiIsProgrammer
Copy link
Author

as far as i can see no it doesnt.

@lovell
Copy link
Owner

lovell commented Aug 6, 2020

Thanks, are there any other native dependencies? What is the output of the following commands?

cd C:\Users\cmart\Documents\tcg\tcgbe
npm ls nan node-addon-api
npm ls -g nan node-addon-api

@CaiIsProgrammer
Copy link
Author

npm ls nan node-addon-api

TcgBackEnd@1.0.0 C:\Users\cmart\Documents\tcg\tcgbe +-- node-libcurl@2.2.0 | -- nan@2.14.1
-- resemblejs@3.2.5 -- canvas@2.6.1
`-- nan@2.14.1 deduped

`

npm ls -g nan node-addon-api
C:\Users\cmart\AppData\Roaming\npm -- (empty)`

@CaiIsProgrammer
Copy link
Author

alright uninstalled it all working now ty

@lovell
Copy link
Owner

lovell commented Aug 6, 2020

canvas@2.6.1 is node-canvas so you've run into #2125 (comment)

@lovell lovell closed this as completed Aug 6, 2020
@lovell lovell changed the title The specified procedure could not be found. \\?\C:\Users\cmart\Documents\tcg\tcgbe\node_modules\sharp\build\Release\sharp.node The specified procedure could not be found, with canvas as dependency Jan 24, 2021
@lovell lovell changed the title The specified procedure could not be found, with canvas as dependency Windows: The specified procedure could not be found, with canvas as dependency Jan 24, 2021
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

2 participants