Closed joshy closed 6 months ago
Hi,
It seems that the error you get is quite similar to this one ?
Hi @juba , thanks for the fast response. I had also installed npx
additionally to pyobsplot
, maybe that was the reason. Now I get another error, but maybe it is due to my setup. I have install jupyter on a server and the notebook is created from there.
ValueError: Server not started: npm ERR! code ENOENT
npm ERR! syscall spawn sh
npm ERR! path [/var/www/jarvis/Auswertung/ge-migration](https://jupyter.imaging.ms.uhbs.ch/lab/tree/Auswertung/ge-migration/Auswertung/ge-migration)
npm ERR! errno -2
npm ERR! enoent spawn sh ENOENT
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in: [/home/jarvis/.npm/_logs/2024-05-03T11_07_47_112Z-debug-0.log](https://jupyter.imaging.ms.uhbs.ch/home/jarvis/.npm/_logs/2024-05-03T11_07_47_112Z-debug-0.log)
34 http fetch GET 200 https://registry.npmjs.org/pyobsplot 702ms (cache revalidated)
35 timing arborist:ctor Completed in 1ms
36 timing command:exec Completed in 954ms
37 verbose stack Error: spawn sh ENOENT
37 verbose stack at ChildProcess._handle.onexit (node:internal/child_process:286:19)
37 verbose stack at onErrorNT (node:internal/child_process:484:16)
37 verbose stack at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
38 verbose cwd /var/www/jarvis/Auswertung/ge-migration
39 verbose Linux 5.10.0-25-amd64
40 verbose node v20.12.2
41 verbose npm v10.5.0
42 error code ENOENT
43 error syscall spawn sh
44 error path /var/www/jarvis/Auswertung/ge-migration
45 error errno -2
46 error enoent spawn sh ENOENT
47 error enoent This is related to npm not being able to find a file.
47 error enoent
48 verbose exit -2
49 timing npm Completed in 1106ms
50 verbose code -2
51 error A complete log of this run can be found in: /home/jarvis/.npm/_logs/2024-05-03T11_07_47_112Z-debug-0.log
What version of nodejs and npm are you using? Thanks a lot for your time!
If your jupyter installation is on a remote server, is the pyobsplot npm package installed there ?
Ok it was my fault. I had node
installed via nvm
. However pythons shutil.which("npx")
was returning None. For that to fix I added the following to my systemd
service file:
Environment="PATH=/home/jarvis/.nvm/versions/node/v20.12.2/bin:$PATH"
The problem is that with systemd the $PATH is not expanded. So probably node executable was not found. I fixed it by changing $PATH
to all the paths and now jsdom
renderer is working. Thanks for your time and help.
Glad to know it is fixed !
Hi
I am trying to use the jsdom renderer but I get the following error (latest pyobsplot==0.4.2):
Thanks for any help!