Open uinstinct opened 1 week ago
Python 3.12 and above does not contain setuptools and breaks node-gyp.
brew install python@3.11
Thanks for the tip! Installed python 3.11 using brew
I got another error on npm i -D
again:
• loaded configuration file=package.json ("build" field)
• rebuilding native dependencies dependencies=keytar@7.9.0 platform=darwin arch=arm64
⨯ cannot execute cause=exit status 1
errorOut=npm ERR! code 1
npm ERR! path /Users/instinct/Desktop/anytype-ts/node_modules/keytar
npm ERR! command failed
npm ERR! command sh -c prebuild-install || npm run build
npm ERR! > keytar@7.9.0 build
npm ERR! > node-gyp rebuild
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.4.1
npm ERR! gyp info using node@20.13.1 | darwin | arm64
npm ERR! gyp info find Python using Python version 3.13.0 found at "/opt/homebrew/opt/python@3.13/bin/python3.13"
npm ERR! gyp info spawn /opt/homebrew/opt/python@3.13/bin/python3.13
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args '/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'make',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/instinct/Desktop/anytype-ts/node_modules/keytar/build/config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/instinct/.electron-gyp/33.0.1/include/node/common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=/Users/instinct/.electron-gyp/33.0.1',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/instinct/.electron-gyp/33.0.1/<(target_arch)/node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/instinct/Desktop/anytype-ts/node_modules/keytar',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! Traceback (most recent call last):
npm ERR! File "/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/gyp/gyp_main.py", line 42, in <module>
npm ERR! import gyp # noqa: E402
npm ERR! ^^^^^^^^^^
npm ERR! File "/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/gyp/pylib/gyp/__init__.py", line 9, in <module>
npm ERR! import gyp.input
npm ERR! File "/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/gyp/pylib/gyp/input.py", line 19, in <module>
npm ERR! from distutils.version import StrictVersion
npm ERR! ModuleNotFoundError: No module named 'distutils'
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: `gyp` failed with exit code: 1
npm ERR! gyp ERR! stack at ChildProcess.onCpExit (/Users/instinct/Desktop/anytype-ts/node_modules/node-gyp/lib/configure.js:325:16)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:519:28)
npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:294:12)
npm ERR! gyp ERR! System Darwin 24.0.0
npm ERR! gyp ERR! command "/Users/instinct/.nvm/versions/node/v20.13.1/bin/node" "/Users/instinct/Desktop/anytype-ts/node_modules/.bin/node-gyp" "rebuild"
npm ERR! gyp ERR! cwd /Users/instinct/Desktop/anytype-ts/node_modules/keytar
npm ERR! gyp ERR! node -v v20.13.1
npm ERR! gyp ERR! node-gyp -v v9.4.1
npm ERR! gyp ERR! not ok
npm ERR! A complete log of this run can be found in: /Users/instinct/.npm/_logs/2024-11-06T11_50_22_244Z-debug-0.log
command=/Users/instinct/.nvm/versions/node/v20.13.1/bin/node /Users/instinct/.nvm/versions/node/v20.13.1/lib/node_modules/npm/bin/npm-cli.js rebuild keytar@7.9.0
workingDir=
npm ERR! code 1
You have still 3.13 trying to run by node-gyp, you should remove it
gyp info find Python using Python version 3.13.0 found at "/opt/homebrew/opt/python@3.13/bin/python3.13"
@ra3orblade You have pretty old stack here in the repo. Are there any plans to up it?
@ra3orblade You have pretty old stack here in the repo. Are there any plans to up it?
of course there are, no time for this at the moment as there are some outdated dependencies and some code needs rework.
Have you read a contributing guide?
Current Behavior
antype-ts fails during installation with the following error on macos silicon
it seems to be some problem with keytar
Expected Behavior
It should install by following the instructions on README
Steps To Reproduce
npm i
Environment
Anything else?
No response