Coder Social home page Coder Social logo

Comments (6)

mgautam07 avatar mgautam07 commented on May 22, 2024 1

@Vin-it using yarn install --ignore-optional did not give the error.
@Shpigford can the issue be closed since installing cypress works fine for both me and vin-it and the issue is not reproducible?

from maybe.

Shpigford avatar Shpigford commented on May 22, 2024

@ethernet6 Can you give more info about the machine you're working from?

from maybe.

ethernet6 avatar ethernet6 commented on May 22, 2024

Specs: Win 10 Pro 22H2 64-bit Intel Duo i5 2.2 GHz, 12 GB RAM
Yarn version 1.22.21
Npm version 9.5.1
WSL version 2

Running from command line.

from maybe.

mgautam07 avatar mgautam07 commented on May 22, 2024

I received many warnings during installation, however none related to Cypress. It seems that cypress was installed correctly. However I received an error while downloading an optional dependency "msgpackr-extract" which I believe is because Visual Studio is not installed on my system.

from maybe.

Vin-it avatar Vin-it commented on May 22, 2024

I received many warnings during installation, however none related to Cypress. It seems that cypress was installed correctly. However I received an error while downloading an optional dependency "msgpackr-extract" which I believe is because Visual Studio is not installed on my system.

I tried installing with Node v18.17.0 and v20.10.0. When using v20.10.0 I get the following error related to msgpackr-extract

Click here to see the error
warning Error running install script for optional dependency: "/Users/user123/git/maybe/node_modules/msgpackr-extract: Command failed.
Exit code: 1
Command: node-gyp-build
Arguments:
Directory: /Users/user123/git/maybe/node_modules/msgpackr-extract
Output:
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info find Python using Python version 3.11.6 found at \"/usr/local/opt/[email protected]/bin/python3.11\"

gyp info spawn /usr/local/opt/[email protected]/bin/python3.11
gyp info spawn args [
gyp info spawn args '/Users/user123/.nvm/versions/node/v20.10.0/lib/node_modules/npm/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/user123/git/maybe/node_modules/msgpackr-extract/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/user123/.nvm/versions/node/v20.10.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/user123/Library/Caches/node-gyp/20.10.0/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/user123/Library/Caches/node-gyp/20.10.0',
gyp info spawn args '-Dnode_gyp_dir=/Users/user123/.nvm/versions/node/v20.10.0/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/Users/user123/Library/Caches/node-gyp/20.10.0/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/Users/user123/git/maybe/node_modules/msgpackr-extract',
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 ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  CXX(target) Release/obj.target/msgpackr-extract/src/extract.o
In file included from ../src/extract.cpp:11:
In file included from ../node_modules/nan/nan.h:178:
../node_modules/nan/nan_callbacks.h:55:23: error: no member named 'AccessorSignature' in namespace 'v8'
typedef v8::Local<v8::AccessorSignature> Sig;
                  ~~~~^
In file included from ../src/extract.cpp:11:
../node_modules/nan/nan.h:684:39: warning: 'IdleNotificationDeadline' is deprecated: Use MemoryPressureNotification() to influence the GC schedule. [-Wdeprecated-declarations]
    return v8::Isolate::GetCurrent()->IdleNotificationDeadline(
                                      ^
/Users/user123/Library/Caches/node-gyp/20.10.0/include/node/v8-isolate.h:1291:3: note: 'IdleNotificationDeadline' has been explicitly marked deprecated here
  V8_DEPRECATE_SOON(
  ^
/Users/user123/Library/Caches/node-gyp/20.10.0/include/node/v8config.h:550:39: note: expanded from macro 'V8_DEPRECATE_SOON'
# define V8_DEPRECATE_SOON(message) [[deprecated(message)]]
                                      ^
In file included from ../src/extract.cpp:11:
../node_modules/nan/nan.h:2544:8: error: no matching member function for call to 'SetAccessor'
  tpl->SetAccessor(
  ~~~~~^~~~~~~~~~~
/Users/user123/Library/Caches/node-gyp/20.10.0/include/node/v8-template.h:816:8: note: candidate function not viable: no known conversion from 'imp::Sig' (aka 'int') to 'v8::SideEffectType' for 7th argument
  void SetAccessor(
       ^
/Users/user123/Library/Caches/node-gyp/20.10.0/include/node/v8-template.h:809:8: note: candidate function not viable: no known conversion from 'imp::NativeGetter' (aka 'void (*)(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value> &)') to 'v8::AccessorGetterCallback' (aka 'void (*)(Local<v8::String>, const PropertyCallbackInfo<v8::Value> &)') for 2nd argument
  void SetAccessor(
       ^
1 warning and 2 errors generated.
make: *** [Release/obj.target/msgpackr-extract/src/extract.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.<anonymous> (/Users/user123/.nvm/versions/node/v20.10.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:209:23)
gyp ERR! System Darwin 23.1.0
gyp ERR! command \"/Users/user123/.nvm/versions/node/v20.10.0/bin/node\" \"/Users/user123/.nvm/versions/node/v20.10.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js\" \"rebuild\"
gyp ERR! cwd /Users/user123/git/maybe/node_modules/msgpackr-extract

I did some digging and found this issue.

bull package in this repo depends on msgpackr which depends on msgpackr-extract which has nan 2.14.2, the fix is in nan 2.17.0 ("fix" here means, fix for Node 20)
One thing to note here is msgpackr -> msgpackr-extract is an optional dependency

@mgautam07 so you could try with Node v18 or try installing with yarn install --ignore-optional to validate if that was the issue

This brings me to the question, what version of npm/node should be used while installing? (Perhaps, should be added to the README? or add an .nvmrc - sorry, if I missed)?

from maybe.

tmyracle avatar tmyracle commented on May 22, 2024

Since #218 was merged moving to pnpm going to close this out, please feel free to re-open if the issue persists.

from maybe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.