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

npm install fibers with error(node v12.15.0) #449

Open
xinxin11 opened this issue Mar 3, 2021 · 8 comments
Open

npm install fibers with error(node v12.15.0) #449

xinxin11 opened this issue Mar 3, 2021 · 8 comments

Comments

@xinxin11
Copy link

xinxin11 commented Mar 3, 2021

Hi could you help investigate this issue?

npm install

> fibers@1.0.15 install /Users/cindy/CIS/CIS_UI_E2E/node_modules/wdio-sync/node_modules/fibers
> node build.js || nodejs build.js

  CXX(target) Release/obj.target/fibers/src/fibers.o
../src/fibers.cc:70:58: error: no template named 'Handle'
        void Reset(Isolate* isolate, Persistent<T>& persistent, Handle<T> handle) {
                                                                ^
../src/fibers.cc:83:26: error: no template named 'Handle'
        void SetInternalPointer(Handle<T> handle, int index, void* val) {
                                ^
../src/fibers.cc:87:27: error: no template named 'Handle'
        void* GetInternalPointer(Handle<T> handle, int index) {
                                 ^
../src/fibers.cc:92:2: error: no template named 'Handle'
        Handle<T> Deref(Isolate* isolate, Persistent<T>& handle) {
        ^
../src/fibers.cc:97:14: error: no template named 'Handle'
        void Return(Handle<T> handle, const Arguments& args) {
                    ^
../src/fibers.cc:101:14: error: no template named 'Handle'
        void Return(Handle<T> handle, GetterCallbackInfo info) {
                    ^
../src/fibers.cc:109:2: error: no template named 'Handle'
        Handle<Value> ThrowException(Isolate* isolate, Handle<Value> exception) {
        ^
../src/fibers.cc:109:49: error: no template named 'Handle'
        Handle<Value> ThrowException(Isolate* isolate, Handle<Value> exception) {
                                                       ^
../src/fibers.cc:113:2: error: no template named 'Handle'
        Handle<Context> GetCurrentContext(Isolate* isolate) {
        ^
../src/fibers.cc:114:10: error: no viable conversion from returned value of type 'Local<v8::Context>' to function return type 'int'
                return isolate->GetCurrentContext();
                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/fibers.cc:117:2: error: no template named 'Handle'
        Handle<Primitive> Undefined(Isolate* isolate) {
        ^
../src/fibers.cc:118:10: error: no viable conversion from returned value of type 'Local<v8::Primitive>' to function return type 'int'
                return v8::Undefined(isolate);
                       ^~~~~~~~~~~~~~~~~~~~~~
../src/fibers.cc:121:2: error: no template named 'Handle'
        Handle<String> NewLatin1String(Isolate* isolate, const char* string) {
        ^
../src/fibers.cc:122:64: error: too few arguments to function call, expected at least 3, have 2
                return String::NewFromOneByte(isolate, (const uint8_t*)string);
                       ~~~~~~~~~~~~~~~~~~~~~~                                ^
/Users/cindy/Library/Caches/node-gyp/12.15.0/include/node/v8.h:2948:3: note: 'NewFromOneByte' declared here
  static V8_WARN_UNUSED_RESULT MaybeLocal<String> NewFromOneByte(
  ^
../src/fibers.cc:125:2: error: no template named 'Handle'
        Handle<String> NewLatin1Symbol(Isolate* isolate, const char* string) {
        ^
../src/fibers.cc:126:64: error: too few arguments to function call, expected at least 3, have 2
                return String::NewFromOneByte(isolate, (const uint8_t*)string);
                       ~~~~~~~~~~~~~~~~~~~~~~                                ^
/Users/cindy/Library/Caches/node-gyp/12.15.0/include/node/v8.h:2948:3: note: 'NewFromOneByte' declared here
  static V8_WARN_UNUSED_RESULT MaybeLocal<String> NewFromOneByte(
  ^
../src/fibers.cc:129:2: error: no template named 'Handle'
        Handle<Boolean> NewBoolean(Isolate* isolate, bool value) {
        ^
../src/fibers.cc:130:10: error: no viable conversion from returned value of type 'Local<v8::Boolean>' to function return type 'int'
                return Boolean::New(isolate, value);
                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/fibers.cc:133:2: error: no template named 'Handle'
        Handle<Number> NewNumber(Isolate* isolate, double value) {
        ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
make: *** [Release/obj.target/fibers/src/fibers.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/Users/cindy/.nvm/versions/node/v12.15.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:223:5)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 19.6.0
gyp ERR! command "/Users/cindy/.nvm/versions/node/v12.15.0/bin/node" "/Users/cindy/.nvm/versions/node/v12.15.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--release"
gyp ERR! cwd /Users/cindy/CIS/CIS_UI_E2E/node_modules/wdio-sync/node_modules/fibers
gyp ERR! node -v v12.15.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok 
node-gyp exited with code: 1
Please make sure you are using a supported platform and node version. If you
would like to compile fibers on this machine please make sure you have setup your
build environment--
Windows + OS X instructions here: https://github.com/nodejs/node-gyp
Ubuntu users please run: `sudo apt-get install g++ build-essential`
Alpine users please run: `sudo apk add python make g++`
sh: nodejs: command not found
npm WARN babel-loader@6.4.1 requires a peer of webpack@1 || 2 || ^2.1.0-beta || ^2.2.0-rc but none is installed. You must install peer dependencies yourself.
npm WARN CIS-UI-e2e@0.0.1 No license field.

npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! fibers@1.0.15 install: `node build.js || nodejs build.js`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the fibers@1.0.15 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/cindy/.npm/_logs/2021-03-03T06_52_29_620Z-debug.log

From the README if you are running 64-bit nodejs version 12.x or 14.x on Linux, OS X, or Windows (7 or later) then you should be able to install fibers from npm just fine.
I checked my node version is v12.15.0 and my machine is mac os which should run npm install

when I changed the node tov6.10.2, there is no such error. but I need upgrade node version to v12.15.0 or higher version now, When I run same command npm install, I see the above error, What I need do for node v12.15.0 to reslove this issue?

@laverdet
Copy link
Owner

laverdet commented Mar 3, 2021

upgrade fibers

@GuyChatfield
Copy link

i am seeing the same for the latest fibers version, (5.0.0) with node 12.16.3. the post install script seems to be from fibers@3.1.1 despite installing 5.0.0?

@gavmck
Copy link

gavmck commented May 21, 2021

Just piping in to say I installed fibers 5.0.0 on node 14.6.0 and now everything works great again. Thanks!

@advancedsoftwarecanada
Copy link

Thank you! This took forever to figure out. Working on the exact same versions as gavmck above.

@advancedsoftwarecanada
Copy link

Ugh annoying. Going to start removing fibers.

nvm install 16
nvm use 16
npm install fibers

Works as of 6/18/2024

@laverdet
Copy link
Owner

@advancedsoftwarecanada fibers has been obsolete for 4 years [e2a0ed9] and entirely unsupported for 3 years [8f28098].

@tcf909
Copy link

tcf909 commented Jun 19, 2024

@advancedsoftwarecanada fibers has been obsolete for 4 years [e2a0ed9] and entirely unsupported for 3 years [8f28098].

But, was absolutely amazing and a true shame for the community to lose :)

And only responding because the throught of this project brings a smile to my face -- truly what JS / Node should have been :)

@laverdet
Copy link
Owner

Yeah I'm definitely proud of what I built! Happy to be "prior art" in the history book. async/await was definitely the right choice for JS. With fibers you can have hundreds of pending stack. With async/await you can have millions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants