sabo10o29 / MMM-TimeTreeEvent

Display your TimeTree event on your magic mirror.
5 stars 0 forks source link

black screen #13

Open nicolasbeyer opened 2 years ago

nicolasbeyer commented 2 years ago

Hi all

My MM works fine. I installed TimeTreeEvent and add the module in my config file. I added my personnal access token and for calenderid I put my Calender app id (I created a Calendar App on TimeTree dev, I put my public IP as webhook). I tried too my my calendar ID. But when I launch MM, I have only a black screen. If i remove the module command line in my config.js, it works...

If someone could help me

Thanks

dragonmann1998 commented 2 years ago

I guess I have found a fix for this Problem. I was trying to develop my own version of a TimeTree Module, but I am a javascript beginner. I mean, a REAL beginner. But I managed to get some things working, but nothing to display on the mirror. So I googled for the path of the mirror logs (home/pi/.pm2/logs). I developed a bit further, but could not manage to produce something useful. So I tried to enable this module again and check the logs if I would find some clues in there. I found out, that the "request" module is not automatically installed. so I installed it in the "~/MagicMirror/modules/MMM-TimeTreeEvent" directory with the following commands: npm init --yes npm install request --save But before you install "request", I suggest, you save the package.json and package-lock.json from the MMM-TimeTreeEvent folder. After the installation, of "request", I replaced the newly generated package.json files with the original ones. When I tied to start the mirror, it would no longer stop at a black screen.

But the TimeTree module would still not show. So I rechecked the logs and had an error regarding the node_helper.js file in the MMM-TimeTree folder:

[29.07.2022 16:19.13.593] [ERROR] ReferenceError: Log is not defined at Request._callback (/home/pi/MagicMirror/modules/MMM-TimeTreeEvent/node_helper.js:30:5)

So I replaced the "Log.log" statement from line 30 with the "console.log" statement. After another restart of the mirror, I got it working as its intended

I hope I can help someone else with this description. This solution cost me a better part of a week. If you need any more help, feel free to ask.

PS: sorry for my bad English :D

sabo10o29 commented 1 year ago

We apologize for the very late response. The following may be the cause https://forum.magicmirror.builders/topic/15778/fix-for-black-screen-in-2-16-and-later I have made this bug fix in the latest release.