garronej / chan-dongle-extended-pages

https://garronej.github.io/chan-dongle-extended-pages/
8 stars 5 forks source link

An error occurred: 'Cannot read property '1' of null #2

Closed kalhori124 closed 2 years ago

kalhori124 commented 2 years ago

Hi,

I get this error while installation.

image

garronej commented 2 years ago

I am very sorry about that.
The message is too vague for me to do anything.
If you are confortable with Node.js you can try to run the code directly and see what's up:
https://github.com/garronej/chan-dongle-extended
If you have a more precise error message, I might be able to help you.

I recommend reading the December 2021 update section of the website https://garronej.github.io/chan-dongle-extended-pages/

StarTakko commented 2 years ago

I have the same problem, Raspberry pi 4

Operating System: Raspbian GNU/Linux 10 (buster) Kernel: Linux 5.10.103-v7l+ Architecture: arm

garronej commented 2 years ago

It needs to be built flr newer

StarTakko commented 2 years ago

It needs to be built flr newer

Yup, Error found

node-pre-gyp ERR! Tried to download(404): https://github.com/EmergingTechnologyAdvisors/node-serialport/releases/download/4.0.7/serialport-v4.0.7-node-v57-linux-arm.tar.gz node-pre-gyp ERR! Pre-built binaries not found for serialport@4.0.7 and node@8.9.4 (node-v57 ABI, glibc) (falling back to source compile with node-gyp)

Same with udev

garronej commented 2 years ago

Sorry I didn't finish my answer the other day.
chan-dongle-extended needs to be build for newer Rasperry pi architecture.
I don't have newer rasperry pi, if you give me access to your rasperry pi via SSH I can try to build it for you.
You can also try to build it yourself: https://github.com/garronej/chan-dongle-extended
If you do it would be cool to send me the bundle so that I can publish it for everybody.

garronej commented 2 years ago

@StarTakko Good news!
It has been built for RasperryPi4

image
MatejKovacic commented 1 year ago

I have run into the same error. I have RaspberryPi 4, running RasPBX (Raspbian GNU/Linux 10 (buster)): uname -a : Linux raspbx 5.10.103-v7l+ #1529 SMP Tue Mar 8 12:24:00 GMT 2022 armv7l GNU/Linux

wget -nc -q -O - garronej.github.io/chan-dongle-extended-pages/install.sh | sudo bash

[sudo] password for matej: 
/tmp/dongle.tar.gz  100%[===================>]  24,98M  2,26MB/s    in 11s     
Extracting.........................................................................---Installing chan_dongle---
Installing or upgrading git package...DONE
Looking for python ... python executable found. OK
Installing or upgrading python-pip package...DONE
Looking for python-setuptools ... python-setuptools is installed. OK
Installing virtualenv...DONE
Looking for build-essential ... build-essential is installed. OK
Installing or upgrading libudev-dev package...DONE
Building node_modules dependencies if needed...DONE
An error occurred: 'Cannot read property '1' of null
MatejKovacic commented 1 year ago

OK, what I did next...

curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
sudo npm install -g npm@latest-5

git clone https://github.com/garronej/chan-dongle-extended

cd chan-dongle-extended/

npm run partial_install
npm run release

That went well. Then I run:

npm install

And got this error:

...
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack     at ChildProcess.emit (events.js:198:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Linux 5.10.103-v7l+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release/serialport.node" "--module_name=serialport" "--module_path=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release"
gyp ERR! cwd /home/matej/chan-dongle-extended/node_modules/serialport
gyp ERR! node -v v10.24.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok 
make: *** [serialport.target.mk:97: Release/obj.target/serialport/src/serialport.o] Error 1
make: Leaving directory '/home/matej/chan-dongle-extended/node_modules/serialport/build'
node-pre-gyp ERR! build error 
node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release/serialport.node --module_name=serialport --module_path=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/home/matej/chan-dongle-extended/node_modules/serialport/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:198:13)
node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:982:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
node-pre-gyp ERR! System Linux 5.10.103-v7l+
node-pre-gyp ERR! command "/usr/bin/node" "/home/matej/chan-dongle-extended/node_modules/serialport/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /home/matej/chan-dongle-extended/node_modules/serialport
node-pre-gyp ERR! node -v v10.24.0
node-pre-gyp ERR! node-pre-gyp -v v0.6.39
node-pre-gyp gypERR! not ok 
Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release/serialport.node --module_name=serialport --module_path=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release' (1)
 ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack     at ChildProcess.emit (events.js:198:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Linux 5.10.103-v7l+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release/serialport.node" "--module_name=serialport" "--module_path=/home/matej/chan-dongle-extended/node_modules/serialport/build/Release"
gyp ERR! cwd /home/matej/chan-dongle-extended/node_modules/serialport
gyp ERR! node -v v10.24.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! serialport@github:EmergingTechnologyAdvisors/node-serialport#4a2a3cfae7ecba4e22e9c6d4cf7dfb7ec64324f6 install: `node-pre-gyp install --fallback-to-build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the serialport@github:EmergingTechnologyAdvisors/node-serialport#4a2a3cfae7ecba4e22e9c6d4cf7dfb7ec64324f6 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!     /home/matej/.npm/_logs/2022-12-07T21_26_24_765Z-debug.log

Any idea what does it mean?

MatejKovacic commented 1 year ago

2022-12-07T21_26_24_765Z-debug.log