@striiker I guess this forum got too crowded to have everything solved properly. I feel you.
Read the statement by Michael Teeuw here.
Posts
-
RE: module calendar showing full day events one day to long
-
RE: WARN notice [SECURITY] lodash has the following vulnerability....
@mwel1977 Experienced the same. npm is doing audits now. Don’t know since when. However they are not errors, only vulnerabilities.
Do anpm auditand find out more about them.
-
RE: Why keeps MM2 starting even when I've pressed ctrl+Q?
@mwel1977 The reason seems to be pm2. You seem to have that installed. It runs a script always restarting MagicMirror after you close it.
To close MagicMirror properly if you have pm2 running do apm2 stop mmor however your process was called. You can find the name of the process running
pm2 statusOther useful commands
pm2 restart mm pm2 start mm.sh //Name of the shell file that has been created by YOU! -
RE: module calendar showing full day events one day to long
@striiker
I need to disagree here.
MagicMirror does not need kludge hacks!
It needs development!I am 100% sure your 5-hours-restart-hack can be solved without the workaround.
-
RE: module calendar showing full day events one day to long
Well this MAY be it. calendarfetcher.js
if (typeof event.end !== "undefined") { endDate = eventDate(event, "end"); } else if(typeof event.duration !== "undefined") { dur=moment.duration(event.duration); endDate = startDate.clone().add(dur);if duration is EXACTLY 24h for a full day event, we would land up at the next day with this .add-function
You COULD try the following:Go into calendarfetcher.js and change in line 96
endDate = startDate.clone().add(dur);to something like
endDate = startDate.clone().add(dur-10000);I can’t do it, I’m at work and REALLY need to go back to it now :-)
EDIT: …well, I needed to try. That’s not the solution. But it should be somewhere in that file :-)
-
RE: module calendar showing full day events one day to long
Here’s the relevant code:
} else { /* Check to see if the user displays absolute or relative dates with their events * Also check to see if an event is happening within an 'urgency' time frameElement * For example, if the user set an .urgency of 7 days, those events that fall within that * time frame will be displayed with 'in xxx' time format or moment.fromNow() * * Note: this needs to be put in its own function, as the whole thing repeats again verbatim */ if (this.config.timeFormat === "absolute") { if ((this.config.urgency > 1) && (event.startDate - now < (this.config.urgency * oneDay))) { // This event falls within the config.urgency period that the user has set timeWrapper.innerHTML = this.capFirst(moment(event.startDate, "x").fromNow()); } else { timeWrapper.innerHTML = this.capFirst(moment(event.startDate, "x").format(this.config.fullDayEventDateFormat)); } } else { timeWrapper.innerHTML = this.capFirst(moment(event.startDate, "x").fromNow()); } } if(this.config.showEnd){ timeWrapper.innerHTML += "-" ; timeWrapper.innerHTML += this.capFirst(moment(event.endDate , "x").format(this.config.fullDayEventDateFormat)); }You can see in the end, that an end to the date is created if showEnd is true. So as far as I can see it, it all comes down to what
event.endDategenerates.
-
RE: module calendar showing full day events one day to long
@andurii Without looking close on it, I could imagine it’s a matter of timestamps being interpreted by the moment() function.
If a full date event creates two timestamps that translate to “Today 0:00:000 - Tomorrow 0:00:000” then it would include tomorrow in the MM translation.
However, I’m not sure about this. Will check into it as well. Interesting topic.And you’re right, showEnd: false is not more than a workaround.
-
RE: MMM-Random Fact
Well for me this module does not work as well (only showing “Eine Tatsache bekommen” in German) and I have again Unhandled Rejection Warnings, which are not errors however… but I have the feeling they are related to the problem.
(node:25288) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error 0|mm | (node:25288) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. 0|mm | (node:25288) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 2): ErrorI only get these when I activate this module
-
RE: Npm not working
However, I have the strong feeling that the ~30€ for a Pi 3b might be well invested to save from further trouble. :-)
Or you use ubuntu in a VM as @Mykle1 suggested -
RE: Npm not working
Well as far as I can see you installed/copied the ARM version of nodejs on a amd64 system.
I guess that does not work.
I’d rather try the Linux x64 binaries. -
RE: MMM-Remote-Control works on Remote Interface but not on Mirror
@5m3d1n4 Well that’s odd, wouldn’t have guessed this. But I’m happy for you it works.
-
RE: MMM-Random Fact
@ramez to be honest, it doesn’t work again. Can’t really find the reason for that.
My confige entry:{ disabled: false, module: 'MMM-rfacts', position: 'top_right', config: { lang: "de", //facts will be translated to this language according to ISO-639$ updateInterval: 10 * 60 * 1000, // every 10 minutes animationSpeed: 10, initialLoadDelay: 875, // 0 seconds delay retryDelay: 1500, fadeSpeed: 7 } },IN the pm2 logs I only get this
0|mm | (node:10423) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 53): Error -
RE: MMM-Random Fact
@lavolp3 module works after a complete reboot. Sorry for the bothering :-)
-
RE: MMM-Random Fact
My module fails as well and I blame the following message in my developer’s console
[Violation] 'message' handler took 767msIt is not directly linked to the module but is coming up since I had it installed just now
-
RE: Default Calender relative removes start time
A bit offtopic, sorry, but wanted to write it down:
The (quite) new ‘dateheaders’ option is a bit odd.
It neglects most of the other options like urgency, today/tomorrow, getrelative, showEnd (i.e. shows only the starting time of an event).
I guess it would need to be placed somewhere else in the code and be more integrated. -
RE: Default Calender relative removes start time
@bkeyport that’s what I would recommend otherwise as well.
I’m using the same config with the timeFormat: ‘dateheaders’ but for some reason I’m missing the ending times… -
RE: Default Calender relative removes start time
@cptkex
You could try thistimeWrapper.innerHTML = this.capFirst(moment(event.startDate, "x").fromNow()) + this.capFirst(moment(event.startDate, "x").format(this.config.dateEndFormat));I took the dirty way to use the dateEndFormat variable for a starting time.
This is just a guess! I haven’t tried it out yet… -
RE: Default Calender relative removes start time
@cptkex There is an open issue that might describe the same issue:
https://github.com/MichMich/MagicMirror/issues/1457
Yours?
Else it might be worth following. -
RE: MMM-Remote-Control works on Remote Interface but not on Mirror
@5m3d1n4 This may be a problem with a module, not necessarily with the networking config.
Please post results ofpm2 logson the mirror itself
and also have a look at the developer’s console on the browser (usually press F12 when you have loaded MM in the browser and find the “console” tab). There you can see the messages created by Javascript loading the modules.