[FIXED] MMM-CalendarExt Facebook birtday events shown on two days



  • Hi!

    Just discovered this project a couple of days ago and have to say I’m hooked! I love this module and all it’s freedom of setup and config.

    One problem though, I’ve imported the Facebook birthdays but they are shown over two days like the event is started at 23:59. Importing the same url in google calendar works fine and thew events are yearly reoccurring and only displayed one one day. Have been at it for days. Tried everything I could think off especially in the localisation area but nothing I do seems to make any difference.

    All other calendars work fine.

    Is this a know issue? anyone know a workaround? Any help is greatly appreciated!

    Also notice the difference in CSS formatting of the 2 FB events (square vs rounded).
    0_1518378705199_Capture.JPG

    {
    			module: 'MMM-CalendarExt',
    			position: "top_left", //anywhere. It is not related to real position of view
    			config: { // Read below
    			  system: {
    				show: ['daily'],
    				locale: 'nl-NL',
    				fullDayEventLocalize: 1,
    				redrawInterval: 60000, //minimum 60000
    			  },
    			  defaultView: {
    			  dateFormat: "D MMM",
    			  fullDayEventDateFormat: "D MMM",
    			  oneLineEvent:0,
    			  overflowRolling: 1,
    			  overflowHeight: 400,
    			  overflowDuration: 5,
    			  weekdayFormat: 'dddd',
    			  },
    			  calendars: [
    				{
    				url: "https://calendar.google.com/calendar/ical/*****%40gmail.com/private-***************/basic.ics"
    				},
    				{
    				name: 'Facebook', 
    				styleName:"style5",
    				symbol:"facebook-f",
    				url: 'webcal://www.facebook.com/ical/b.php?uid=********&key=*******'
    				},
    								{
    				name: 'Holidays', 
    				styleName:"style20",
    				symbol:"flag-nl@em",
    				url: "https://calendar.google.com/calendar/ical/nl.dutch%23holiday%40group.v.calendar.google.com/public/basic.ics"
    				},
    				{
    				name: 'Ajax', 
    				styleName:"style1",
    				symbol:"soccer@em",
    				url: "https://www.google.com/calendar/ical/kc4eeg2****0group.calendar.google.com/public/basic.ics"
    				}
    			  ]
    			}
    		},
    


  • so no one has seen this? does anyone use the facebook ical in their MMM-CalendarExt without a problem?

    thx.



  • @modderhut What is the time zone for your MM? What is the time zone of your FB birthday feed/file? You can open an ics in any text editor. If they’re the same, it may not be getting properly interpreted.



  • Thanks for your answer!

    I guess MM is taking the timezone from the Pi and thats set to Amsterdam (GMT +1). The facebook link for the birthdays is not a actual file and can’t be opened with text editor but I am able to import the data into excel (need to change the url from “webcal” to “http” for that to work )

    I have played with all settings related to timezone that I can think off but see no change, also commenting out the module’s locale setting does not change time, only formatting. same for the “fullDayEventLocalize”

    One thing I noticed is that the Facebook events come in as 00:00 - 23:59 probably causing it to be displayed on two days. When I change the show: [‘daily’] to show: [‘monthly’] the time is still displayed as 00:00 - 23:59 but the events are only sown on the correct day.
    If there was a problem with a localisation or time zone setting I would expect a deviation of full hours not 1 minute.

    The Facebook data in excel does not show a locale setting any time or locale (see below) which makes me think the MMM-Calendar module translates “DURATION:P1D” into “00:00 - 23:59” somehow but are unable to spot that in the code.

    BEGIN:VCALENDAR
    PRODID:-//Facebook//NONSGML Facebook Events V1.0//EN
    X-WR-CALNAME:Friends’ Birthdays
    X-PUBLISHED-TTL:PT12H
    X-ORIGINAL-URL:/events/birthdays/
    VERSION:2.0
    CALSCALE:GREGORIAN
    METHOD:PUBLISH
    BEGIN:VEVENT
    DTSTART:20180217
    SUMMARY:Bert birthday
    RRULE:FREQ=YEARLY
    DURATION:P1D
    UID:@facebook.com
    END:VEVENT
    BEGIN:VEVENT
    DTSTART:20180218
    SUMMARY:Wouter birthday
    RRULE:FREQ=YEARLY
    DURATION:P1D
    UID:
    @facebook.com
    END:VEVENT

    can anyone confirm they import facebook birtdays and they look ok for them?



  • @modderhut Strange that ['monthly'] displays correctly, but ['daily'] doesn’t. I don’t use the FB feed, so can’t confirm. For reference, this is handled in components/Calendar.js which passes the duration (e.g. P1D) to moment, which returns the start/end times. However, they should all fall on the same day (i.e. 00:00 and 23:59).

    cc. @Sean


  • Module Developer

    Ok. I caught where the bugs from. I will fix it in a few hours. then I’ll reply about this again. you can update then.



  • The code changes by Sean have fixed the problem, thanks for your quick follow up! The birthday events from Facebook now show up as whole day events on the correct dates.



  • I have the same issue, but with an ical calendar. All full day evens are shown on two days in both daily and weeks view. I have connected the same ical calendar to my Oulook and there it works fine.

    Any suggestions?



  • @nn1mda What is the time zone of the calendar, and of your mirror?



  • @nn1mda When you ruled out time config mistakes log an issue on the Github module page https://github.com/eouia/MMM-CalendarExt/issues . The developer is very fast with support but I think he only monitors those issues and not actively monitors this forum.

    Please update this threat when you solve it s we all can benefit from the solution.

    good luck!