node.js – Metaplex candymachine Error: Cannot find module ‘../build/Release/canvas.node’
I entered the instructions in Metaplex.
ts-node '/Users/mac-book/metaplex/js/packages/cli/src/candy-machine-v2-cli.ts' --version
Result :
Error: Cannot find module '../build/Release/canvas.node'
Require stack:
- /Users/mac-book/metaplex/js/node_modules/canvas/lib/bindings.js
- /Users/mac-book/metaplex/js/node_modules/canvas/lib/canvas.js
- /Users/mac-book/metaplex/js/node_modules/canvas/index.js
- /Users/mac-book/metaplex/js/packages/cli/src/commands/createArt.ts
- /Users/mac-book/metaplex/js/packages/cli/src/candy-machine-v2-cli.ts
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at
Function.Module._resolveFilename.sharedData.moduleResolveFilenameHook.installedValue
[as _resolveFilename] (/usr/local/lib/node_modules/ts-node/node_modules/@cspotcode/source-map-support/source-map-support.js:679:30)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/Users/mac-book/metaplex/js/node_modules/canvas/lib/bindings.js:3:18)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/Users/mac-book/metaplex/js/node_modules/canvas/lib/bindings.js',
'/Users/mac-book/metaplex/js/node_modules/canvas/lib/canvas.js',
'/Users/mac-book/metaplex/js/node_modules/canvas/index.js',
'/Users/mac-book/metaplex/js/packages/cli/src/commands/createArt.ts',
'/Users/mac-book/metaplex/js/packages/cli/src/candy-machine-v2-cli.ts'
]
}
There’s an error saying that you couldn’t find the module. How do I solve this problem?
All the tools for using metaplex are installed in the latest stable version.
and My environment is macOS M1.
Read more here: Source link