You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The original issue is posted below which is related to setup of a node repo. While doing the setup I am facing issue with node-gyp and python. citrineos/citrineos#45
@cclauss Can you please help here. I followed the thread #2664
But no luck. let me know if you need any other info to guide me better.
Below is the configuration of my system:
I am getting this error while hitting the command on readme : "docker-compose -f ./docker-compose.yml up -d"
Also note that I have Python 3.9.6 and not Python 3.11.2, I am assuming node-gyp might not be able to find with 'python' as I have python3. Do I need to tag python with python3 with some alias, I tried this also taking reference from some post, but still no luck.
amanjha@192 server % python3 --version
Python 3.9.6
amanjha@192 server % python --version
xcode-select: Failed to locate 'python', requesting installation of command line developer tools.
amanjha@192 server % which -a python
/usr/local/bin/python
amanjha@192 server % which -a python3
/usr/bin/python3
/opt/homebrew/bin/python3
/opt/homebrew/bin/python3
amanjha@192 server %
Earlier I tried below commands, but now I have reverted.
open ~/.zshrc
alias python3="/opt/homebrew/bin/python3"
export PYTHON="/opt/homebrew/bin/python3"
Thanks @cclauss for pointing out. I am using corporate laptop and it has zscalar so I might be running these behind a proxy. Is there a way to setup a my personal cert that node can use. Can you provide some reference.
I am running into a similar issue. Bellow is the error output. I suspect that this has to do with the operating system version not being compatible with node-gyp. Running 15.1.1.
I am also using a corporate machine that has VPN / proxy / firewalls.
Error
npm i
npm warn deprecated inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
npm warn deprecated rimraf@2.6.3: Rimraf versions prior to v4 are no longer supported
npm warn deprecated rimraf@2.7.1: Rimraf versions prior to v4 are no longer supported
npm warn deprecated rimraf@2.7.1: Rimraf versions prior to v4 are no longer supported
npm warn deprecated rimraf@2.7.1: Rimraf versions prior to v4 are no longer supported
npm warn deprecated @humanwhocodes/config-array@0.13.0: Use @eslint/config-array instead
npm warn deprecated abab@2.0.6: Use your platform's native atob() and btoa() methods instead
npm warn deprecated rimraf@3.0.2: Rimraf versions prior to v4 are no longer supported
npm warn deprecated @humanwhocodes/object-schema@2.0.3: Use @eslint/object-schema instead
npm warn deprecated glob@8.1.0: Glob versions prior to v9 are no longer supported
npm warn deprecated glob@7.1.7: Glob versions prior to v9 are no longer supported
npm warn deprecated domexception@4.0.0: Use your platform's native DOMException instead
npm warn deprecated q@1.4.1: You or someone you depend on is using Q, the JavaScript Promise library that gave JavaScript developers strong feelings about promises. They can almost certainly migrate to the native JavaScript promise now. Thank you literally everyone for joining me in this bet against the odds. Be excellent to each other.
npm warn deprecated
npm warn deprecated (For a CapTP with native promises, see @endo/eventual-send and @endo/captp)
npm warn deprecated @types/googlemaps@3.43.3: Types for the Google Maps browser API have moved to @types/google.maps. Note: these types are not for the googlemaps npm package, which is a Node API.
npm warn deprecated eslint@8.57.1: This version is no longer supported. Please see https://eslint.org/version-support for other options.
npm error code 1
npm error path /Users/na/Developer/acme/web-app/node_modules/weak-napi
npm error command failed
npm error command sh -c node-gyp-build
npm error CC(target) Release/obj.target/nothing/../node-addon-api/nothing.o
npm error LIBTOOL-STATIC Release/nothing.a
npm error CXX(target) Release/obj.target/weakref/src/weakref.o
npm error gyp info it worked if it ends with ok
npm error gyp info using node-gyp@10.3.1
npm error gyp info using node@22.13.0 | darwin | arm64
npm error gyp info find Python using Python version 3.9.6 found at "/Users/na/.pyenv/versions/3.9.6/bin/python3"
npm error gyp info spawn /Users/na/.pyenv/versions/3.9.6/bin/python3
npm error gyp info spawn args [
npm error gyp info spawn args '/Users/na/Developer/acme/web-app/node_modules/node-gyp/gyp/gyp_main.py',
npm error gyp info spawn args 'binding.gyp',
npm error gyp info spawn args '-f',
npm error gyp info spawn args 'make',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/Users/na/Developer/acme/web-app/node_modules/weak-napi/build/config.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/Users/na/Developer/acme/web-app/node_modules/node-gyp/addon.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/Users/na/Library/Caches/node-gyp/22.13.0/include/node/common.gypi',
npm error gyp info spawn args '-Dlibrary=shared_library',
npm error gyp info spawn args '-Dvisibility=default',
npm error gyp info spawn args '-Dnode_root_dir=/Users/na/Library/Caches/node-gyp/22.13.0',
npm error gyp info spawn args '-Dnode_gyp_dir=/Users/na/Developer/acme/web-app/node_modules/node-gyp',
npm error gyp info spawn args '-Dnode_lib_file=/Users/na/Library/Caches/node-gyp/22.13.0/<(target_arch)/node.lib',
npm error gyp info spawn args '-Dmodule_root_dir=/Users/na/Developer/acme/web-app/node_modules/weak-napi',
npm error gyp info spawn args '-Dnode_engine=v8',
npm error gyp info spawn args '--depth=.',
npm error gyp info spawn args '--no-parallel',
npm error gyp info spawn args '--generator-output',
npm error gyp info spawn args 'build',
npm error gyp info spawn args '-Goutput_dir=.'
npm error gyp info spawn args ]
npm error gyp info spawn make
npm error gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm error warning: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: archive library: Release/nothing.a the table of contents is empty (no object file members in the library define global symbols)
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:515:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/search.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/iterator_operations.h:12:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/iter_swap.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__utility/swap.h:16:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_nothrow_move_constructible.h:15:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_nothrow_constructible.h:17:
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstddef:46:5: error: <cstddef> tried including <stddef.h> but didn't find libc++'s <stddef.h> header. This usually means that your header search paths are not configured properly. The header search paths should contain the C++ Standard Library headers before any C Standard Library, and you are probably using compiler flags that make that not be the case.
npm error 46 | # error <cstddef> tried including <stddef.h> but didn't find libc++'s <stddef.h> header. \
npm error | ^
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstddef:59:9: error: no member named 'nullptr_t' in the global namespace
npm error 59 | using ::nullptr_t;
npm error | ~~^
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:515:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/search.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/iterator_operations.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/ranges_iterator_concept.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__iterator/concepts.h:16:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__concepts/constructible.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__concepts/destructible.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_nothrow_destructible.h:16:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_scalar.h:17:
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_null_pointer.h:26:28: error: use of undeclared identifier 'nullptr_t'; did you mean 'nullptr'?
npm error 26 | struct __is_nullptr_t_impl<nullptr_t> : public true_type {};
npm error | ^
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_null_pointer.h:26:28: error: template argument for template type parameter must be a type
npm error 26 | struct __is_nullptr_t_impl<nullptr_t> : public true_type {};
npm error | ^~~~~~~~~
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_null_pointer.h:23:17: note: template parameter is declared here
npm error 23 | template <class _Tp>
npm error | ^
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:515:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/search.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/iterator_operations.h:15:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__iterator/advance.h:26:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/limits:819:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/type_traits:508:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_trivially_copyable.h:14:
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstdint:149:5: error: <cstdint> tried including <stdint.h> but didn't find libc++'s <stdint.h> header. This usually means that your header search paths are not configured properly. The header search paths should contain the C++ Standard Library headers before any C Standard Library, and you are probably using compiler flags that make that not be the case.
npm error 149 | # error <cstdint> tried including <stdint.h> but didn't find libc++'s <stdint.h> header. \
npm error | ^
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:521:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__functional/bind.h:20:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/tuple:272:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/compare:145:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/compare_partial_order_fallback.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/partial_order.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/weak_order.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/strong_order.h:20:
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:322:5: error: <cmath> tried including <math.h> but didn't find libc++'s <math.h> header. This usually means that your header search paths are not configured properly. The header search paths should contain the C++ Standard Library headers before any C Standard Library, and you are probably using compiler flags that make that not be the case.
npm error 322 | # error <cmath> tried including <math.h> but didn't find libc++'s <math.h> header. \
npm error | ^
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:583:15: error: expected unqualified-id
npm error 583 | return std::isnan(__lcpp_x);
npm error | ^
npm error /usr/local/include/math.h:166:5: note: expanded from macro 'isnan'
npm error 166 | ( sizeof(x) == sizeof(float) ? __inline_isnanf((float)(x)) \
npm error | ^
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:521:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__functional/bind.h:20:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/tuple:272:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/compare:145:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/compare_partial_order_fallback.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/partial_order.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/weak_order.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/strong_order.h:20:
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:582:46: error: no return statement in constexpr function
npm error 582 | _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool __constexpr_isnan(_A1 __lcpp_x) _NOEXCEPT {
npm error | ^
npm error /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:597:15: error: expected unqualified-id
npm error 597 | return std::isinf(__lcpp_x);
npm error | ^
npm error /usr/local/include/math.h:161:5: note: expanded from macro 'isinf'
npm error 161 | ( sizeof(x) == sizeof(float) ? __inline_isinff((float)(x)) \
npm error | ^
npm error In file included from ../src/weakref.cc:1:
npm error In file included from /Users/na/Developer/acme/web-app/node_modules/node-addon-api/napi.h:5:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/functional:521:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__functional/bind.h:20:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/tuple:272:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/compare:145:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/compare_partial_order_fallback.h:13:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/partial_order.h:14:
npm error In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__compare/weak_order.h:14:
....
Activity
cclauss commentedon Nov 6, 2024
Please paste in text, not pictures. Pictures are not searchable or quotable but text is.
Your problem here is not related to Python. Python 3.11.2 was found at
/usr/bin/python3which works.brew install pythonThe problem is related to the
FetchError.unaccepted commentedon Nov 6, 2024
Thanks @cclauss for the response, please find the reponse of the last command (docker-compose -f ./docker-compose.yml up -d) in text:
I have also created binding.gyp file with below content:
{ "targets": [ { "target_name": "binding", "sources": [ " /usr/local/bin/node" ] } ] }Also note that I have Python 3.9.6 and not Python 3.11.2, I am assuming node-gyp might not be able to find with 'python' as I have python3. Do I need to tag python with python3 with some alias, I tried this also taking reference from some post, but still no luck.
Earlier I tried below commands, but now I have reverted.
alias python3="/opt/homebrew/bin/python3"
export PYTHON="/opt/homebrew/bin/python3"
cclauss commentedon Nov 6, 2024
Means that Python is NOT your problem.
Your problem is:
unaccepted commentedon Nov 6, 2024
Thanks @cclauss for pointing out. I am using corporate laptop and it has zscalar so I might be running these behind a proxy. Is there a way to setup a my personal cert that node can use. Can you provide some reference.
nazarioa commentedon Jan 14, 2025
I am running into a similar issue. Bellow is the error output. I suspect that this has to do with the operating system version not being compatible with node-gyp. Running 15.1.1.
I am also using a corporate machine that has VPN / proxy / firewalls.
Error
sepc
cclauss commentedon Mar 19, 2025
For all of the examples above, Python is not the problem. A supported version of Python was found and is being used.
Please tell us which module you are trying to install.
npm itells us nothing.