Magic Mirror only shows black screen



  • Hey,
    i’m fairly new to the scene. After working on the config file for the whole day it suddenly wouldn’t start anymore. No config file error. Just a black screen.

    I ran my config file through: https://esprima.org/demo/validate.html
    and it said valid.

    pi@raspberrypi:~ $ cd ~/MagicMirror
    pi@raspberrypi:~/MagicMirror $ npm start
    
    > magicmirror@2.8.0 start /home/pi/MagicMirror
    > sh run-start.sh
    
    Starting MagicMirror: v2.8.0
    Loading config ...
    Loading module helpers ...
    No helper found for module: alert.
    WARNING! Could not load config file. Starting with default configuration. Error found: Error: Cannot find module 'node_helper'
    Loading module helpers ...
    No helper found for module: alert.
    App threw an error during load
    Error: Cannot find module 'node_helper'
        at Module._resolveFilename (internal/modules/cjs/loader.js:602:15)
        at Function.Module._resolveFilename (/home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/common/reset-search-paths.js:35:12)
        at Function.Module._load (internal/modules/cjs/loader.js:528:25)
        at Module.require (internal/modules/cjs/loader.js:658:17)
        at require (internal/modules/cjs/helpers.js:20:18)
        at Object. (/home/pi/MagicMirror/modules/default/updatenotification/node_helper.js:6:18)
        at Object. (/home/pi/MagicMirror/modules/default/updatenotification/node_helper.js:94:3)
        at Module._compile (internal/modules/cjs/loader.js:711:30)
        at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10)
        at Module.load (internal/modules/cjs/loader.js:620:32)
    Whoops! There was an uncaught exception...
    { Error: Cannot find module 'node_helper'
        at Module._resolveFilename (internal/modules/cjs/loader.js:602:15)
        at Function.Module._resolveFilename (/home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/common/reset-search-paths.js:35:12)
        at Function.Module._load (internal/modules/cjs/loader.js:528:25)
        at Module.require (internal/modules/cjs/loader.js:658:17)
        at require (internal/modules/cjs/helpers.js:20:18)
        at Object. (/home/pi/MagicMirror/modules/default/updatenotification/node_helper.js:6:18)
        at Object. (/home/pi/MagicMirror/modules/default/updatenotification/node_helper.js:94:3)
        at Module._compile (internal/modules/cjs/loader.js:711:30)
        at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10)
        at Module.load (internal/modules/cjs/loader.js:620:32) code: 'MODULE_NOT_FOUND' }
    MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
    If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues
    Launching application.
    Shutting down server...
    

    Can anyone tell me why the file can’t be read
    Thanks


  • Module Developer

    @maddinmirror
    Can you post your config? Make sure all private key or calendar links are removed or changed (xxx) before posting.
    AxLED


  • Project Sponsor

    @maddinmirror So, a few things. Is this a fresh install? Did you run npm install in the MagicMirror after the install? Can you do a shit+ctrl+i to open the developer console? Select the Console Tab and scroll up and look for any errors usually marked in red.


  • Project Sponsor Module Developer

    @maddinmirror said in Magic Mirror only shows black screen:

    After working on the config file for the whole day it suddenly wouldn’t start anymore.

    Undo you’re changes to the config.js file to the point where it was last working.


  • Module Developer

    Here are a few things to do.

    • Check if the Server is still running
      • On the Raspberry Pi open a browser and visit localhost:8080 If you see a black screen the server is still running which is good…
    • Check your changes with git status. Any changes that you didn’t make on purpose? (Especially check the updatenotification module Validate them and revert them if needed
    • Rename your config _config.js (Or someting…) to force the MagicMirror to load the default config.js, check if the expected config file error appears
    • Meditate over your changes you might miss an obvious error in your code
    • Post the censored config.js file here

  • Module Developer

    Your MM has been missing modules/node_modules/node_helper/index.js. (I don’t know why)
    You can copy https://github.com/MichMich/MagicMirror/blob/master/modules/node_modules/node_helper/index.js then paste it as new file and save it to MagicMirror/modules/node_modules/node_helper/index.js.

    Or reinstall MM.



  • @Sean u meant node_helper/index.js
    Right?


  • Module Developer

    @sdetweil yes. Sorry. my mistypo.



  • So the correct path is

    MagicMirror/node_modules/node_helper/index.js

  • Module Developer

    @sdetweil corrected. Thanks. 😃