Skip to content

precompiled packages targeting electron are not available #1467

Open
@ranasaria

Description

@ranasaria

I have developed and tested a package using node-canvas. Everything worked fine. Now I am trying to use my package in another project that is targetting electron environment. Here the download of the canvas package fails because pre-built packages targeting that environmet are not available.

Issue or Feature

Need support for pre-built binaries for electron.

Steps to Reproduce

Use the Canvas package from package.json dependencies section on a project that targets electron environment.

error:
error D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas: Command failed.
Exit code: 1
Command: node-pre-gyp install --fallback-to-build
Arguments:
Directory: D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas
Output:
node-pre-gyp info it worked if it ends with ok
node-pre-gyp info using [email protected]
node-pre-gyp info using [email protected] | win32 | x64
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp info check checked for "D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas\build\Release\canvas.node" (not found)
node-pre-gyp http GET https://github.com/node-gfx/node-canvas-prebuilt/releases/download/v2.6.0/canvas-v2.6.0-electron-v4.2-win32-unknown-x64.tar.gz
node-pre-gyp http 404 https://github.com/node-gfx/node-canvas-prebuilt/releases/download/v2.6.0/canvas-v2.6.0-electron-v4.2-win32-unknown-x64.tar.gz
node-pre-gyp WARN Tried to download(404): https://github.com/node-gfx/node-canvas-prebuilt/releases/download/v2.6.0/canvas-v2.6.0-electron-v4.2-win32-unknown-x64.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (electron-v4.2 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp http 404 status code downloading tarball https://github.com/node-gfx/node-canvas-prebuilt/releases/download/v2.6.0/canvas-v2.6.0-electron-v4.2-win32-unknown-x64.tar.
gz

D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....
\node_modules\node-gyp\bin\node-gyp.js" clean ) else (node "" clean )
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp info ok

D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....
\node_modules\node-gyp\bin\node-gyp.js" configure --fallback-to-build --module=D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas\build\Release\canvas.node -
-module_name=canvas --module_path=D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas\build\Release --napi_version=3 --node_abi_napi=napi --napi_build_version
=0 --node_napi_label=electron-v4.2 ) else (node "" configure --fallback-to-build --module=D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas\build\Release\c
anvas.node --module_name=canvas --module_path=D:\src\azuredatastudio\extensions\integration-tests\node_modules\canvas\build\Release --napi_version=3 --node_abi_napi=napi --napi_b
uild_version=0 --node_napi_label=electron-v4.2 )

Your Environment

Windows Version 1903 (OS build 18362.239)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions