Skip to content
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

pnpm install shows errors #1234

Closed
agyn-ub opened this issue Dec 19, 2024 · 22 comments
Closed

pnpm install shows errors #1234

agyn-ub opened this issue Dec 19, 2024 · 22 comments
Labels
bug Something isn't working

Comments

@agyn-ub
Copy link

agyn-ub commented Dec 19, 2024

I did everything as in tutorial in official documentation. And I run pnpm install
│ 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:14056) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead.
│ (Use node --trace-deprecation ... to show where the warning was created)
│ node-pre-gyp info check checked for "C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules@discordjs\opus\prebu…
│ node-pre-gyp http GET https://github.com/discordjs/opus/releases/download/v0.9.0/opus-v0.9.0-node-v131-napi-v3-win32-x64-un…
│ node-pre-gyp ERR! install response status 404 Not Found on https://github.com/discordjs/opus/releases/download/v0.9.0/opus-…
│ node-pre-gyp WARN Pre-built binaries not installable for @discordjs/[email protected] and [email protected] (node-v131 ABI, unknown) (fa…
│ node-pre-gyp WARN Hit error response status 404 Not Found on https://github.com/discordjs/opus/releases/download/v0.9.0/opu…
│ gyp info it worked if it ends with ok
│ gyp info using [email protected]
│ gyp info using [email protected] | win32 | x64
│ gyp info ok
│ gyp info it worked if it ends with ok
│ gyp info using [email protected]
│ gyp info using [email protected] | win32 | x64
│ gyp info find Python using Python version 3.13.1 found at "C:\Users\agynb\AppData\Local\Programs\Python\Python313\python.ex…
│ gyp ERR! find VS
│ gyp ERR! find VS msvs_version not set from command line or npm config
│ gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
│ gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer, try re-running with '--loglevel silly' for m…
│ gyp ERR! find VS
│ gyp ERR! find VS Failure details: undefined
│ gyp ERR! find VS checking VS2022 (17.11.35327.3) found at:
│ gyp ERR! find VS "C:\Program Files\Microsoft Visual Studio\2022\Community"
│ gyp ERR! find VS - found "Visual Studio C++ core features"
│ gyp ERR! find VS - missing any VC++ toolset
│ gyp ERR! find VS could not find a version of Visual Studio 2017 or newer to use
│ gyp ERR! find VS not looking for VS2017 as it is only supported up to Node.js 21
│ gyp ERR! find VS not looking for VS2017 as it is only supported up to Node.js 21
│ gyp ERR! find VS not looking for VS2017 as it is only supported up to Node.js 21
│ gyp ERR! find VS not looking for VS2015 as it is only supported up to Node.js 18
│ gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
│ gyp ERR! find VS
│ gyp ERR! find VS **************************************************************
│ gyp ERR! find VS You need to install the latest version of Visual Studio
│ gyp ERR! find VS including the "Desktop development with C++" workload.
│ gyp ERR! find VS For more information consult the documentation at:
│ gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
│ gyp ERR! find VS **************************************************************
│ gyp ERR! find VS
│ gyp ERR! configure error
│ gyp ERR! stack Error: Could not find any Visual Studio installation to use
│ gyp ERR! stack at VisualStudioFinder.fail (C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules\node-gyp\lib\fi…
│ gyp ERR! stack at VisualStudioFinder.findVisualStudio (C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules\nod…
│ gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
│ gyp ERR! stack at async createBuildDir (C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules\node-gyp\lib\confi…
│ gyp ERR! stack at async run (C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules\node-gyp\bin\node-gyp.js:81:1…
│ gyp ERR! System Windows_NT 10.0.26100
│ gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_mo…
│ gyp ERR! cwd C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules@discordjs\opus
│ gyp ERR! node -v v23.3.0
│ gyp ERR! node-gyp -v v10.3.1
│ gyp ERR! not ok
│ node-pre-gyp ERR! build error
│ node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\agynb\OneDrive\Рабочий стол\Eli…
│ node-pre-gyp ERR! stack at ChildProcess. (C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules@…
│ node-pre-gyp ERR! stack at ChildProcess.emit (node:events:513:28)
│ node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1101:16)
node_modules/canvas: Running install script, failed in 10.7s (skipped as optional)process:305:5)
│ node-pre-gyp ERR! System Windows_NT 10.0.26100
│ node-pre-gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza…
│ node-pre-gyp ERR! cwd C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules@discordjs\opus
│ node-pre-gyp ERR! node -v v23.3.0
│ node-pre-gyp ERR! node-pre-gyp -v v0.4.5
│ node-pre-gyp ERR! not ok
│ Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules\node-g…
└─ Failed in 10.4s at C:\Users\agynb\OneDrive\Рабочий стол\Eliza\f1\eliza\node_modules@discordjs\opus

@agyn-ub agyn-ub added the bug Something isn't working label Dec 19, 2024
@giorgosn
Copy link

are you using WSL 2?

@digitalsimboja
Copy link

~/dev/eliza #v0.1.6-alpha.4 pnpm install ✔ 23.3.0 ⬢ 11:00:24 AM
Scope: all 46 workspace projects
Lockfile is up to date, resolution step is skipped
 ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)

Your Node version is incompatible with "@lens-protocol/[email protected](@lens-protocol/[email protected])([email protected])([email protected])".

Expected version: >=18 <21
Got: v23.3.0

This is happening because the package's manifest has an engines.node field specified.
To fix this issue, install the required Node version.
~/dev/eliza #v0.1.6-alpha.4

I get this issue as well

@agyn-ub
Copy link
Author

agyn-ub commented Dec 19, 2024

are you using WSL 2?

no. I am in linux pop_os

@agyn-ub
Copy link
Author

agyn-ub commented Dec 19, 2024

I run pnpm install on lunix the same error
│ CC(target) Release/obj.target/libopus/deps/opus/celt/pitch.o
│ rm -f Release/obj.target/deps/opus.a Release/obj.target/deps/opus.a.ar-file-list; mkdir -p dirname Release/obj.target/deps/opus.a
│ ar crs Release/obj.target/deps/opus.a @Release/obj.target/deps/opus.a.ar-file-list
│ COPY Release/opus.a
│ CXX(target) Release/obj.target/opus/src/node-opus.o
│ : warning: ISO C++11 requires whitespace after the macro name
│ ../src/node-opus.cc:1:10: fatal error: napi.h: No such file or directory
│ 1 | #include "napi.h"
│ | ^~~~~~~~
│ compilation terminated.
│ make: *** [opus.target.mk:157: Release/obj.target/opus/src/node-opus.o] Error 1
│ make: Leaving directory '/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus/build'
│ gyp ERR! build error
│ gyp ERR! stack Error: make failed with exit code: 2
│ gyp ERR! stack at ChildProcess. (/home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/lib/build.js:216:23)
│ gyp ERR! System Linux 6.9.3-76060903-generic
│ gyp ERR! command "/home/agyn/.nvm/versions/node/v23.3.0/bin/node" "/home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--modul…
│ gyp ERR! cwd /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
│ gyp ERR! node -v v23.3.0
│ gyp ERR! node-gyp -v v10.3.1
│ gyp ERR! not ok
│ node-pre-gyp ERR! build error
│ node-pre-gyp ERR! stack Error: Failed to execute '/home/agyn/.nvm/versions/node/v23.3.0/bin/node /home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js build --f…
│ node-pre-gyp ERR! stack at ChildProcess. (/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/node-pre-gyp/lib/util/compile.js:85:20)
│ node-pre-gyp ERR! stack at ChildProcess.emit (node:events:513:28)
│ node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1101:16)
│ node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:305:5)
│ node-pre-gyp ERR! System Linux 6.9.3-76060903-generic
│ node-pre-gyp ERR! command "/home/agyn/.nvm/versions/node/v23.3.0/bin/node" "/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus/node_modules/.bin/node-pre-gyp" "instal…
│ node-pre-gyp ERR! cwd /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
│ node-pre-gyp ERR! node -v v23.3.0
│ node-pre-gyp ERR! node-pre-gyp -v v0.4.5
│ node-pre-gyp ERR! not ok
│ Failed to execute '/home/agyn/.nvm/versions/node/v23.3.0/bin/node /home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home…
└─ Failed in 29.7s at /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
 ELIFECYCLE  Command failed with exit code 1.

@agyn-ub
Copy link
Author

agyn-ub commented Dec 19, 2024

~/dev/eliza #v0.1.6-alpha.4 pnpm install ✔ 23.3.0 ⬢ 11:00:24 AM Scope: all 46 workspace projects Lockfile is up to date, resolution step is skipped  ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)

Your Node version is incompatible with "@lens-protocol/[email protected](@lens-protocol/[email protected])([email protected])([email protected])".

Expected version: >=18 <21 Got: v23.3.0

This is happening because the package's manifest has an engines.node field specified. To fix this issue, install the required Node version. ~/dev/eliza #v0.1.6-alpha.4

I get this issue as well

the same error
│ CC(target) Release/obj.target/libopus/deps/opus/silk/enc_API.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/biquad_alt.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/quant_LTP_gains.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/resampler_private_down_FIR.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/ana_filt_bank_1.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/stereo_MS_to_LR.o
│ CC(target) Release/obj.target/libopus/deps/opus/silk/decode_indices.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/rate.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/entdec.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/modes.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/celt_lpc.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/laplace.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/cwrs.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/celt.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/entcode.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/celt_decoder.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/celt_encoder.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/mdct.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/quant_bands.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/vq.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/bands.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/kiss_fft.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/entenc.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/mathops.o
│ CC(target) Release/obj.target/libopus/deps/opus/celt/pitch.o
│ rm -f Release/obj.target/deps/opus.a Release/obj.target/deps/opus.a.ar-file-list; mkdir -p dirname Release/obj.target/deps/opus.a
│ ar crs Release/obj.target/deps/opus.a @Release/obj.target/deps/opus.a.ar-file-list
│ COPY Release/opus.a
│ CXX(target) Release/obj.target/opus/src/node-opus.o
│ : warning: ISO C++11 requires whitespace after the macro name
│ ../src/node-opus.cc:1:10: fatal error: napi.h: No such file or directory
│ 1 | #include "napi.h"
│ | ^~~~~~~~
│ compilation terminated.
│ make: *** [opus.target.mk:155: Release/obj.target/opus/src/node-opus.o] Error 1
│ make: Leaving directory '/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus/build'
│ gyp ERR! build error
│ gyp ERR! stack Error: make failed with exit code: 2
│ gyp ERR! stack at ChildProcess. (/home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/lib/build.js:216:23)
│ gyp ERR! System Linux 6.9.3-76060903-generic
│ gyp ERR! command "/home/agyn/.nvm/versions/node/v20.18.1/bin/node" "/home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--modu…
│ gyp ERR! cwd /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
│ gyp ERR! node -v v20.18.1
│ gyp ERR! node-gyp -v v10.3.1
│ gyp ERR! not ok
│ node-pre-gyp ERR! build error
│ node-pre-gyp ERR! stack Error: Failed to execute '/home/agyn/.nvm/versions/node/v20.18.1/bin/node /home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js build --…
│ node-pre-gyp ERR! stack at ChildProcess. (/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/node-pre-gyp/lib/util/compile.js:85:20)
│ node-pre-gyp ERR! stack at ChildProcess.emit (node:events:518:28)
│ node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1104:16)
│ node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:304:5)
│ node-pre-gyp ERR! System Linux 6.9.3-76060903-generic
│ node-pre-gyp ERR! command "/home/agyn/.nvm/versions/node/v20.18.1/bin/node" "/home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus/node_modules/.bin/node-pre-gyp" "insta…
│ node-pre-gyp ERR! cwd /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
│ node-pre-gyp ERR! node -v v20.18.1
│ node-pre-gyp ERR! node-pre-gyp -v v0.4.5
│ node-pre-gyp ERR! not ok
│ Failed to execute '/home/agyn/.nvm/versions/node/v20.18.1/bin/node /home/agyn/Desktop/AI agents/j2/eliza/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/hom…
└─ Failed in 38.1s at /home/agyn/Desktop/AI agents/j2/eliza/node_modules/@discordjs/opus
node_modules/canvas: Running install script, done in 21.5s
 ELIFECYCLE  Command failed with exit code 1.

@agyn-ub
Copy link
Author

agyn-ub commented Dec 19, 2024

~/dev/eliza #v0.1.6-alpha.4 pnpm install ✔ 23.3.0 ⬢ 11:00:24 AM Scope: all 46 workspace projects Lockfile is up to date, resolution step is skipped  ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)

Your Node version is incompatible with "@lens-protocol/[email protected](@lens-protocol/[email protected])([email protected])([email protected])".

Expected version: >=18 <21 Got: v23.3.0

This is happening because the package's manifest has an engines.node field specified. To fix this issue, install the required Node version. ~/dev/eliza #v0.1.6-alpha.4

I get this issue as well

thank you so much my friend, I have downgraded node version to 18 is command executed ok. It is confusing because in the documentation were written that it must be node version 23+

@digitalsimboja
Copy link

~/dev/eliza #v0.1.6-alpha.4 pnpm install ✔ 23.3.0 ⬢ 11:00:24 AM Scope: all 46 workspace projects Lockfile is up to date, resolution step is skipped  ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)
Your Node version is incompatible with "@lens-protocol/[email protected](@lens-protocol/[email protected])([email protected])([email protected])".
Expected version: >=18 <21 Got: v23.3.0
This is happening because the package's manifest has an engines.node field specified. To fix this issue, install the required Node version. ~/dev/eliza #v0.1.6-alpha.4
I get this issue as well

thank you so much my friend, I have downgraded node version to 18 is command executed ok. It is confusing because in the documentation were written that it must be node version 23+

I have a hell of dependencies issues. How did you downgrade yours to version 18 without conflicting with other projects? Did you change the node engine specifications from 23+ to 18?

@ileana-pr
Copy link
Contributor

I have seen this discord/opus error before.. try the fix in this file: https://heavenly-tellurium-f00.notion.site/Issues-15ee77534fe980b89fd6e92a5c80d5a0?pvs=4

let me know if it solves the issue.

@agyn-ub
Copy link
Author

agyn-ub commented Dec 20, 2024

~/dev/eliza #v0.1.6-alpha.4 pnpm install ✔ 23.3.0 ⬢ 11:00:24 AM Scope: all 46 workspace projects Lockfile is up to date, resolution step is skipped  ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)
Your Node version is incompatible with "@lens-protocol/[email protected](@lens-protocol/[email protected])([email protected])([email protected])".
Expected version: >=18 <21 Got: v23.3.0
This is happening because the package's manifest has an engines.node field specified. To fix this issue, install the required Node version. ~/dev/eliza #v0.1.6-alpha.4
I get this issue as well

thank you so much my friend, I have downgraded node version to 18 is command executed ok. It is confusing because in the documentation were written that it must be node version 23+

I have a hell of dependencies issues. How did you downgrade yours to version 18 without conflicting with other projects? Did you change the node engine specifications from 23+ to 18?

I Used nvm. in the nvm list I have node js version 18 and 23. and for Eliza project I used command "nvm use 18".

@agyn-ub
Copy link
Author

agyn-ub commented Dec 20, 2024

I have seen this discord/opus error before.. try the fix in this file: https://heavenly-tellurium-f00.notion.site/Issues-15ee77534fe980b89fd6e92a5c80d5a0?pvs=4

let me know if it solves the issue.

thank you for offering me a potential solution. I have just downgraded node js version to 18 using nvm and it helped me. And it is ok for me to continue a journey to Eliza framework.

@Nith567
Copy link

Nith567 commented Dec 20, 2024

@agyn-ub i have downgraded to nodejs 18 still facing same issue
telegram-cloud-photo-size-5-6282768028940746815-y

@Nith567
Copy link

Nith567 commented Dec 20, 2024

Here is my issue irrespective of nodejs version it show same . My device is Mac m1

node_modules/@discordjs/opus: Running install script, failed in 3s
node_modules/@discordjs/opus install$ node-pre-gyp install --fallback-to-build
│ 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] | darwin | arm64
│ node-pre-gyp info check checked for "/Users/nithin/eliza/node_modules/@discordjs/opus/prebuild/node-v108-napi-v3-darwin-arm64-unknown-unknown/opus.node" (not found)
│ node-pre-gyp http GET https://github.com/discordjs/opus/releases/download/v0.9.0/opus-v0.9.0-node-v108-napi-v3-darwin-arm64-unknown-unknown.tar.gz
│ node-pre-gyp ERR! install response status 404 Not Found on https://github.com/discordjs/opus/releases/download/v0.9.0/opus-v0.9.0-node-v108-napi-v3-darwin-arm64-unknown…
│ node-pre-gyp WARN Pre-built binaries not installable for @discordjs/[email protected] and [email protected] (node-v108 ABI, unknown) (falling back to source compile with node-gyp)
│ node-pre-gyp WARN Hit error response status 404 Not Found on https://github.com/discordjs/opus/releases/download/v0.9.0/opus-v0.9.0-node-v108-napi-v3-darwin-arm64-unkno…
│ gyp info it worked if it ends with ok
│ gyp info using [email protected]
│ gyp info using [email protected] | darwin | arm64
│ gyp info ok
│ gyp info it worked if it ends with ok
│ gyp info using [email protected]
│ gyp info using [email protected] | darwin | arm64
│ gyp info find Python using Python version 3.13.1 found at "/opt/homebrew/opt/[email protected]/bin/python3.13"
│ gyp info spawn /opt/homebrew/opt/[email protected]/bin/python3.13
│ gyp info spawn args [
│ gyp info spawn args '/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/gyp/gyp_main.py',
│ gyp info spawn args 'binding.gyp',
│ gyp info spawn args '-f',
│ gyp info spawn args 'make',
│ gyp info spawn args '-I',
│ gyp info spawn args '/Users/nithin/eliza/node_modules/@discordjs/opus/build/config.gypi',
│ gyp info spawn args '-I',
│ gyp info spawn args '/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/addon.gypi',
│ gyp info spawn args '-I',
│ gyp info spawn args '/Users/nithin/Library/Caches/node-gyp/18.20.5/include/node/common.gypi',
│ gyp info spawn args '-Dlibrary=shared_library',
│ gyp info spawn args '-Dvisibility=default',
│ gyp info spawn args '-Dnode_root_dir=/Users/nithin/Library/Caches/node-gyp/18.20.5',
│ gyp info spawn args '-Dnode_gyp_dir=/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp',
│ gyp info spawn args '-Dnode_lib_file=/Users/nithin/Library/Caches/node-gyp/18.20.5/<(target_arch)/node.lib',
│ gyp info spawn args '-Dmodule_root_dir=/Users/nithin/eliza/node_modules/@discordjs/opus',
│ gyp info spawn args '-Dnode_engine=v8',
│ gyp info spawn args '--depth=.',
│ gyp info spawn args '--no-parallel',
│ gyp info spawn args '--generator-output',
│ gyp info spawn args 'build',
│ gyp info spawn args '-Goutput_dir=.'
│ gyp info spawn args ]
│ Traceback (most recent call last):
│ File "/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/gyp/gyp_main.py", line 42, in
│ import gyp # noqa: E402
│ ^^^^^^^^^^
│ File "/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/gyp/pylib/gyp/init.py", line 9, in
│ import gyp.input
│ File "/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/gyp/pylib/gyp/input.py", line 19, in
│ from distutils.version import StrictVersion
│ ModuleNotFoundError: No module named 'distutils'
│ gyp ERR! configure error
│ gyp ERR! stack Error: gyp failed with exit code: 1
│ gyp ERR! stack at ChildProcess.onCpExit (/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/lib/configure.js:325:16)
│ gyp ERR! stack at ChildProcess.emit (node:events:517:28)
│ gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:292:12)
│ gyp ERR! System Darwin 24.2.0
│ gyp ERR! command "/Users/nithin/.nvm/versions/node/v18.20.5/bin/node" "/usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallb…
│ gyp ERR! cwd /Users/nithin/eliza/node_modules/@discordjs/opus
│ gyp ERR! node -v v18.20.5
│ gyp ERR! node-gyp -v v9.4.0
│ gyp ERR! not ok
│ node-pre-gyp ERR! build error
│ node-pre-gyp ERR! stack Error: Failed to execute '/Users/nithin/.nvm/versions/node/v18.20.5/bin/node /usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/bin/nod…
│ node-pre-gyp ERR! stack at ChildProcess. (/Users/nithin/eliza/node_modules/@discordjs/node-pre-gyp/lib/util/compile.js:85:20)
│ node-pre-gyp ERR! stack at ChildProcess.emit (node:events:517:28)
│ node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1098:16)
│ node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:303:5)
│ node-pre-gyp ERR! System Darwin 24.2.0
│ node-pre-gyp ERR! command "/Users/nithin/.nvm/versions/node/v18.20.5/bin/node" "/Users/nithin/eliza/node_modules/@discordjs/opus/node_modules/.bin/node-pre-gyp" "instal…
│ node-pre-gyp ERR! cwd /Users/nithin/eliza/node_modules/@discordjs/opus
│ node-pre-gyp ERR! node -v v18.20.5
│ node-pre-gyp ERR! node-pre-gyp -v v0.4.5
│ node-pre-gyp ERR! not ok
│ Failed to execute '/Users/nithin/.nvm/versions/node/v18.20.5/bin/node /usr/local/lib/node_modules/pnpm/dist/node_modules/node-gyp/bin/node-gyp.js configure --fallback-t…
└─ Failed in 3s at /Users/nithin/eliza/node_modules/@discordjs/opus
node_modules/@ffmpeg-installer/darwin-arm64: Running postinstall script, done in 283ms
node_modules/@docusaurus/plugin-ideal-image/node_modules/sharp: Running install script...
node_modules/@multiversx/sdk-core/node_modules/keccak: Running install script...
node_modules/@near-js/crypto/node_modules/secp256k1: Running install script...
node_modules/@nestjs/core: Running postinstall script, done in 1.3s
node_modules/@nomicfoundation/ethereumjs-tx/node_modules/secp256k1: Running install script, done in 849ms
 ELIFECYCLE  Command failed with exit code 1.
Failed to install dependencies.

@agyn-ub
Copy link
Author

agyn-ub commented Dec 20, 2024

@agyn-ub i have downgraded to nodejs 18 still facing same issue telegram-cloud-photo-size-5-6282768028940746815-y

I had the exact same error. I today I have tried with nvm node 23 and it is worked. I really wanna help to you, but I don't know what thing is exactly helped me.

@Nith567
Copy link

Nith567 commented Dec 21, 2024

I even upgraded to 23.3.0 version but going through the same issue
Screenshot 2024-12-21 at 11 00 48 PM

@ileana-pr
Copy link
Contributor

Hello, have you tried the Discord Opus solution in this guide? I had the same issue and this helped me solve. Please let me know if it helps to solve that error. https://heavenly-tellurium-f00.notion.site/Issues-15ee77534fe980b89fd6e92a5c80d5a0

@adamsimonini
Copy link

I had this issue on Windows, but not Linux. I have been setting up Eliza Starter on both. On windows, I needed to ensure I had Ubuntu distro installed to WSL, and I had it running for good measure. That seemed to resolve one of my issues with Windows and node-gyp.

I haven't run into the error on Linux. I am using Mint.

@adamsimonini
Copy link

adamsimonini commented Dec 24, 2024

Are you sure you're using Python 2.7.18 (final update for Python 2)? If you have python. If you have multiple versions of python on your machine, that could be the issue.

python -v
'which python'

My base python is python 3.

I am using miniconda to create different conda environments. The one I am using for this project has python 2.7.18 specified

Part of your error message: "gyp info find Python using Python version 3.13.1 found at"

@Nith567
Copy link

Nith567 commented Dec 25, 2024

@ileana-pr guide helped me resolve this issue successfully. Thank you !

@agyn-ub agyn-ub closed this as completed Dec 26, 2024
@ileana-pr
Copy link
Contributor

@ileana-pr guide helped me resolve this issue successfully. Thank you !

Glad to help. Thanks for letting me know it worked for you.

@Nith567
Copy link

Nith567 commented Dec 28, 2024

@ileana-pr
hello i am facing this new issue :

Error sending message: SqliteError: Vector dimension mistmatch. First vector has 768 dimensions, while the second has 384 dimensions.
Error sending message: SqliteError: Vector dimension mistmatch. First vector has 768 dimensions, while the second has 384 dimensions.
    at SqliteDatabaseAdapter.searchMemoriesByEmbedding (file:///Users/nithin/Desktop/aiagents/eliza/packages/adapter-sqlite/dist/index.js:308:47)
    at SqliteDatabaseAdapter.createMemory (file:///Users/nithin/Desktop/aiagents/eliza/packages/adapter-sqlite/dist/index.js:240:48)
    at MemoryManager.createMemory (file:///Users/nithin/Desktop/aiagents/eliza/packages/core/dist/index.js:23031:44)
    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
    at async callback (file:///Users/nithin/Desktop/aiagents/eliza/packages/client-discord/dist/index.js:2140:29)
    at async MessageManager.handleMessage (file:///Users/nithin/Desktop/aiagents/eliza/packages/client-discord/dist/index.js:2149:42) {
  code: 'SQLITE_ERROR'

@ileana-pr
Copy link
Contributor

@Nith567 Looks like a vector mismatch error where discord-client is trying to create a memory but the sqlite adapter is not able to search by embedding. your database may be using a different embedding model than eliza. Check the @eliza/packages/core/src/embeddings.ts file for the configuration details and your .env file to make sure you are using the same provider.

@didintern
Copy link

I had this issue on Windows, but not Linux. I have been setting up Eliza Starter on both. On windows, I needed to ensure I had Ubuntu distro installed to WSL, and I had it running for good measure. That seemed to resolve one of my issues with Windows and node-gyp.

I haven't run into the error on Linux. I am using Mint.

Ill try bro same issues so far

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

7 participants