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

Error while installing ( cannot convert ‘v8::MaybeLocal<v8::String>’ to ‘v8::Local<v8::String>’) #42

Open
evert opened this issue Apr 4, 2023 · 0 comments

Comments

@evert
Copy link

evert commented Apr 4, 2023

These are the first few lines when trying to install this library with node 18.15.0

npm ERR! code 1                                                                                                                  
npm ERR! path /home/evert/src/city/server/node_modules/netcdf4                                                                   
npm ERR! command failed                                                                                                          
npm ERR! command sh -c node-gyp rebuild                                                                                          
npm ERR! make: Entering directory '/home/evert/src/city/server/node_modules/netcdf4/build'                                       
npm ERR!   CXX(target) Release/obj.target/netcdf4/src/Group.o                                                                    
npm ERR! make: Leaving directory '/home/evert/src/city/server/node_modules/netcdf4/build'                                        
npm ERR! gyp info it worked if it ends with ok                                                                                   
npm ERR! gyp info using node-gyp@9.3.1                                                                                           
npm ERR! gyp info using node@18.15.0 | linux | x64                                                                               
npm ERR! gyp info find Python using Python version 3.11.2 found at "/usr/bin/python3"                                            
npm ERR! gyp info spawn /usr/bin/python3                                                                                         
npm ERR! gyp info spawn args [                                                                                                   
npm ERR! gyp info spawn args   '/usr/lib/node_modules_18/npm/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   '/home/evert/src/city/server/node_modules/netcdf4/build/config.gypi',                             
npm ERR! gyp info spawn args   '-I',                                                                                             
npm ERR! gyp info spawn args   '/usr/lib/node_modules_18/npm/node_modules/node-gyp/addon.gypi',                                  
npm ERR! gyp info spawn args   '-I',                                                                                             
npm ERR! gyp info spawn args   '/home/evert/.cache/node-gyp/18.15.0/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=/home/evert/.cache/node-gyp/18.15.0',                                            
npm ERR! gyp info spawn args   '-Dnode_gyp_dir=/usr/lib/node_modules_18/npm/node_modules/node-gyp',                              
npm ERR! gyp info spawn args   '-Dnode_lib_file=/home/evert/.cache/node-gyp/18.15.0/<(target_arch)/node.lib',                    
npm ERR! gyp info spawn args   '-Dmodule_root_dir=/home/evert/src/city/server/node_modules/netcdf4',                             
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! gyp info spawn make                                                                                                     
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]                                                              
npm ERR! In file included from ../src/Group.cpp:6:                                                                               
npm ERR! ../src/netcdf4js.h: In function ‘void netcdf4js::throw_netcdf_error(v8::Isolate*, int)’:                                
npm ERR! ../src/netcdf4js.h:11:77: error: cannot convert ‘v8::MaybeLocal<v8::String>’ to ‘v8::Local<v8::String>’                 
npm ERR!    11 |     isolate->ThrowException(v8::Exception::TypeError(v8::String::NewFromUtf8(isolate, nc_strerror(retval))));   
npm ERR!       |                                                      ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~      
npm ERR!       |                                                                             |                                   
npm ERR!       |                                                                             v8::MaybeLocal<v8::String>          
npm ERR! In file included from /home/evert/.cache/node-gyp/18.15.0/include/node/v8.h:30,                                         
npm ERR!                  from /home/evert/.cache/node-gyp/18.15.0/include/node/node.h:73,                                                                                                                                                                    
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

1 participant