Read the statement by Michael Teeuw here.
MMM-Button doesn't work
-
@cruunnerr Isn’t this just a warning? I have not used this module myself, but as it appears this might not be an actual error that stops you from using the module, or is it?
-
Well, i installed grunt manually and After that i did the “install onoff” again without any issue. But i got the same white blank screen as before. I will make a video to show it better
-
@cruunnerr Can you have a look at the output of the logs? You can use this to stop your mirror, clear the logs, start it up and display the logs:
pm2 stop mm && pm2 flush && pm2 start mm && pm2 logs mm
Have a look at the output and/or post it here (make sure to replace any private stuff in it, if there is any).
I just did a new install of the module, and this installation seems to work (starting in the
module
folder):git clone https://github.com/PtrBld/MMM-Button.git cd MMM-Button npm install
-
[TAILING] Tailing last 10 lines for [mm] process (change the value with --lines option) /home/pi/.pm2/logs/mm-out-0.log last 10 lines: /home/pi/.pm2/logs/mm-error-0.log last 10 lines: [STREAMING] Now streaming realtime logs for [mm] process 0|mm | > magicmirror@2.0.0 start /home/pi/MagicMirror 0|mm | > electron js/electron.js 0|mm | Loading config ... 0|mm | Loading module helpers ... 0|mm | No helper found for module: alert. 0|mm | WARNING! Could not load config file. Starting with default configuration. Error found: Error: Module version mismatch. Expected 50, got 48. 0|mm | Loading module helpers ... 0|mm | No helper found for module: alert. 0|mm | App threw an error during load 0|mm | Error: Module version mismatch. Expected 50, got 48. 0|mm | at Error (native) 0|mm | at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:168:20) 0|mm | at Object.Module._extensions..node (module.js:583:18) 0|mm | at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:168:20) 0|mm | at Module.load (module.js:473:32) 0|mm | at tryModuleLoad (module.js:432:12) 0|mm | at Function.Module._load (module.js:424:3) 0|mm | at Module.require (module.js:483:17) 0|mm | at require (internal/module.js:20:19) 0|mm | at bindings (/home/pi/MagicMirror/modules/MMM-Button/node_modules/bindings/bindings.js:76:44) 0|mm | Whoops! There was an uncaught exception... 0|mm | Error: Module version mismatch. Expected 50, got 48. 0|mm | at Error (native) 0|mm | at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:168:20) 0|mm | at Object.Module._extensions..node (module.js:583:18) 0|mm | at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:168:20) 0|mm | at Module.load (module.js:473:32) 0|mm | at tryModuleLoad (module.js:432:12) 0|mm | at Function.Module._load (module.js:424:3) 0|mm | at Module.require (module.js:483:17) 0|mm | at require (internal/module.js:20:19) 0|mm | at bindings (/home/pi/MagicMirror/modules/MMM-Button/node_modules/bindings/bindings.js:76:44) 0|mm | MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection? 0|mm | If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues 0|mm | Launching application.
Thats what i got after “pm2 logs mm” Internet Connection is absolutly ok.
Edit:
Thats with the Button Module uncommented:
[TAILING] Tailing last 10 lines for [mm] process (change the value with --lines option) /home/pi/.pm2/logs/mm-out-0.log last 10 lines: /home/pi/.pm2/logs/mm-error-0.log last 10 lines: [STREAMING] Now streaming realtime logs for [mm] process 0|mm | > magicmirror@2.0.0 start /home/pi/MagicMirror 0|mm | > electron js/electron.js 0|mm | Loading config ... 0|mm | Loading module helpers ... 0|mm | No helper found for module: alert. 0|mm | Initializing new module helper ... 0|mm | Initializing new module helper ... 0|mm | No helper found for module: clock. 0|mm | Initializing new module helper ... 0|mm | No helper found for module: currentweather. 0|mm | Initializing new module helper ... 0|mm | No helper found for module: weatherforecast. 0|mm | No helper found for module: mmm-weatherchart. 0|mm | Initializing new module helper ... 0|mm | All module helpers loaded. 0|mm | Starting server op port 8080 ... 0|mm | Server started ... 0|mm | Connecting socket for: MMM-SystemStats 0|mm | Connecting socket for: MMM-WatchDog 0|mm | Staring module helper: MMM-WatchDog 0|mm | Connecting socket for: calendar 0|mm | Starting node helper for: calendar 0|mm | Connecting socket for: MMM-WunderGround 0|mm | MMM-WunderGround helper started ... 0|mm | Connecting socket for: newsfeed 0|mm | Starting module: newsfeed 0|mm | Sockets connected & modules started ... 0|mm | (node:3795) DeprecationWarning: sys is deprecated. Use util instead . 0|mm | Launching application. 0|mm | WatchDog started. Maximum timeout: 10s. 0|mm | Create new calendar fetcher for url: *PRIVATE* 0|mm | Create new calendar fetcher for url: *PRIVATE* 0|mm | Create new news fetcher for url: *PRIVATE*
Note from admin: Please use Markdown on code snippets for easier reading!
-
Well, i googled a lot and their seem to be different soloutions. But i don’t want to do anything wrong ^^
some say the npm Version is the problem. Mine is 3.10.3 and my Node-Version is 6.6.0. Dont know if they are the newest… people writing that a simple reinstall of both solve their problem. But i was scared trying that by myself.
Some other say you have to install the module directly via npm instead of clone before. But i am not sure as well.
The only thing i tried was going to the
/MagicMirror/modules/MMM-Button
and do anpm install --save-dev electron-rebuild
. But that didnt solve the problem. Not sure if i was doing it right :(Well, i really try to find a soloution cause i spent much time in the mirror and it worked very well so far, but my english isnt very well and my knowledge about Linux and such that stuff is not so good :/
So i don’t want to do things wrong. Hope (i’m sure) you guys can help me. -
@cruunnerr I had this
module version mismatch
before, too. I updatednode
andnpm
and it went away, but I do not know if that will solve your problem + you seem to have an up to date version. Maybe try and delete yournode_modules
folders (in theMagicMirror
folder and you modules folder, i.e.MagicMirror/modules/MMM-Button
), and do annpm install
again? -
So i did the following:
I succesfully updated npm to 3.10.8. Node told me it is up to date. then I deleted the MMM-Button folder with
rm -rf
. Then i follwed the install-guide again (clone folder, went to MMM-Button andnpm Install
), but get the same result as before! Is the Button-module not compatible with the newest Node/npm Version?What do you mean with deleting the node_modules folder in the MagicMirror directory? o.0 there are many many files. When i deleted it what should i do after that? i am a little bit scared, sorry for asking so many questions. ^^
-
@cruunnerr This folder (
MagicMirror/node_modules
) was created during your installation, so you can safely delete it (but only this folder and everything in it. You just need to do the installation again (anpm install
will create the exact same folders and files). Did you use the automatic installer script?Basically it looks like you have this problem. There are also some suggestions there.
-
So i will delet the node_modules folder in the magicmirror directory. then i go to
cd ~/MagicMirror
and will do anpm install
, right? should i do anpm update
or “npm rebuild” before the install?edit: yes, i used the automatic installer
-
@cruunnerr Yes, that sounds about right, you can try the rebuild thing first.