MagicMirror² v2.8.0 is available! For more information about this release, check out this topic.

nodejs Warnings on recent Stretch-Buster update


  • Project Sponsor

    Hi all,

    Recently I’ve updated my raspbian stretch to raspbian buster on the Raspberry Pi 3 where I have installed MM (v. 2.8.0). Everything goes well, except for one thing. When I launch the following commands (on a bash script):

    #!/bin/bash
    cd ~/MagicMirror
    npm start

    The mirror starts well, but I get these warnings:

    
    npm WARN npm npm does not support Node.js v10.15.2
    npm WARN npm You should probably upgrade to a newer version of node as we
    npm WARN npm can't make any promises that npm will work with this version.
    npm WARN npm Supported releases of Node.js are the latest release of 4, 6, 7, 8, 9.
    npm WARN npm You can find the latest version at https://nodejs.org/
    

    After MM starts, some modules are not showed, and I think maybe is for that reason.

    How could I solve this?
    Thanks in advance!


  • Project Sponsor

    Finally I’ve found the solution looking at the forum:

    sudo npm install npm@latest -g



  • im having the same problem. So all i have to do is run sudo npm install npm@latest -g



  • @qu1que said in nodejs Warnings on recent Stretch-Buster update:

    sudo npm install npm@latest -g

    Hello, tried also under manuell install process to use:

    pi@raspberrypi:~/MagicMirror $ sudo npm install npm@latest -g
    /usr/bin/npm -> /usr/lib/node_modules/npm/bin/npm-cli.js
    /usr/bin/npx -> /usr/lib/node_modules/npm/bin/npx-cli.js
    + npm@6.10.1
    added 19 packages from 13 contributors, removed 12 packages and updated 32 packages in 61.073s
    

    But still:

    pi@raspberrypi:~/MagicMirror $ npm start
    
    > magicmirror@2.8.0 start /home/pi/MagicMirror
    > sh run-start.sh
    
    run-start.sh: 4: run-start.sh: electron: not found
    npm ERR! file sh
    npm ERR! code ELIFECYCLE
    npm ERR! errno ENOENT
    npm ERR! syscall spawn
    npm ERR! magicmirror@2.8.0 start: `sh run-start.sh`
    npm ERR! spawn ENOENT
    npm ERR! 
    npm ERR! Failed at the magicmirror@2.8.0 start script.
    npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
    npm WARN Local package.json exists, but node_modules missing, did you mean to install?
    
    npm ERR! A complete log of this run can be found in:
    npm ERR!     /home/pi/.npm/_logs/2019-07-13T16_53_04_944Z-debug.log
    


  • @Joern from the MagicMirror folder now do again

    npm install 
    


  • @sdetweil said in nodejs Warnings on recent Stretch-Buster update:

    npm install

    Oh that’s looks better & I can start now. Below outcome of installation.
    So what did I do with the line “npm@latest -g” before. Did I define for nom to use older version, that was appliedduring current run of “npm install”?

    pi@raspberrypi:~/MagicMirror $ npm install
    npm WARN deprecated time-grunt@2.0.0: Deprecated because Grunt is practically unmaintained. Move on to something better. This package will continue to work with Grunt v1, but it will not receive any updates.
    
    > electron-chromedriver@1.8.0 install /home/pi/MagicMirror/node_modules/electron-chromedriver
    > node ./download-chromedriver.js
    
    successfully dowloaded and extracted!
    
    > core-js@2.6.9 postinstall /home/pi/MagicMirror/node_modules/core-js
    > node scripts/postinstall || echo "ignore"
    
    Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!
    
    The project needs your help! Please consider supporting of core-js on Open Collective or Patreon: 
    > https://opencollective.com/core-js 
    > https://www.patreon.com/zloirock 
    
    Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)
    
    
    > electron@3.1.10 postinstall /home/pi/MagicMirror/node_modules/electron
    > node install.js
    
    Downloading tmp-2201-1-SHASUMS256.txt-3.1.10
    [============================================>] 100.0% of 4.79 kB (4.79 kB/s)
    
    > magicmirror@2.8.0 install /home/pi/MagicMirror
    > cd vendor && npm install
    
    npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
    npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
    
    added 82 packages from 57 contributors and audited 220 packages in 30.154s
    found 5 vulnerabilities (4 low, 1 high)
      run `npm audit fix` to fix them, or `npm audit` for details
    
    > magicmirror@2.8.0 postinstall /home/pi/MagicMirror
    > sh installers/postinstall/postinstall.sh && npm run install-fonts
    
    MagicMirror installation successful!
    
    > magicmirror@2.8.0 install-fonts /home/pi/MagicMirror
    > cd fonts && npm install
    
    added 1 package from 1 contributor and audited 1 package in 7.521s
    found 0 vulnerabilities
    
    added 1008 packages from 1328 contributors and audited 3572 packages in 299.519s
    found 0 vulnerabilities