Calendar Entries - Scheduled Time One Hour Later Than Set

Yes, I have the same problem with all-day events spilling over into the next day (so a one day all-day event is shown incorrectly as an all-day event for two days).

I had assumed, maybe wrongly, that this was the same, or similar problem, as the issue above, but maybe it’s not.

Technically I suppose an event that runs from midnight to midnight is a two day event (by one minute) and therefore Sailfish is correct to display it as such.

However if this is the accepted practice for representing an all-day event by everybody else then it probably makes sense for Sailfish to recognise this, ignore the single minute overspill and show it as a single all-day event.

At least then the synchronisation would work for this type of event.

Here my TDE creates whole day event with following
DTSTART;VALUE=DATE:20210722
DTEND;VALUE=DATE:20210723

and complies to the information provided here

IMO the best would be to export or send the event, so one could see how it is defined in Sailfish.

See also this discussion from late 2005!

The problem is that we don’t have access to the code of the Exchange plugin so we don’t know what it is doing to convert the iCal format into the internal format used by KCalendarCore and mKCal.

What is sure is that :

  • iCal defines duration in an exclusive way, so an event with a DTSTART at day D and a DTEND at D+2 is a two days long event finishing at the end of day D+1.
  • KCalendarCore and mKCal are using the opposite convention, they are inclusive. event->dtStart() at D and event->dtEnd() at D+1 is an event two days long finishing at the end of D+1.

Normally, using the KCalendarCore::ICalFormat handle this transparently, so reading an iCal serialisation is setting the dtEnd with the right convention.

But mKCal has been broken with respect of this in the past and was not restoring the full day events properly (it mixed up the KCalendarCore and the iCal format conventions). This bug has been solved some years ago, but maybe the workaround in the Exchange plugin has not been removed, creating this bug… No idea once again, depends on sources…

Unfortunately it is a mess. But the fact that the “Standard” is not inclusive and KCalendarCore is inclusive does not mean it is wrong. The convention would be to convert the ical into the proper representation in KCalendarCore and v.v. but you are right that we do not know what the EAS plugin is doing. For me it stopped working long time ago. AFAIK the EAS was in the licensed part, or am I wrong?

If your question is whether Exchange Synchronisation is part of the paid license for Sailfish X, then yes.

In any case I have just booked my holiday and find that Sailfish has given me an extra day, so maybe we’d better leave things!!! :rofl:

1 Like

I have my Xperia 10 II (running the upcoming 4.2.0 release) in the Finnish (EET) local timezone. The calendar entries in my Jolla Exchange calendar, be they created on Xperia or using the Outlook web access, appear at the correct times also after syncing the calendar. I created the events using the Finnish timezone. I have “Automatic update” enabled in “Settings > Time and date”, so this should handle the summertime, too.

In fact, Sailfish has this option. At the end of the settings of Exchange accounts, there are “Advanced settings” which contain the item “Resolve conflicts” with options “Priority to server” (default) and “Priority to device”.

If I may, the problem is occurring when on the server, the calendar is setup to use a UTC time zone. What about the configuration of your server ?

I cannot reproduce personnaly because I’ve no access to an exchange server, so these are information that may not be exact neither to reproduce the bug.

@jovirkku Perhaps one way of you hopefully seeing the problem for yourself is for you to send me an email (steve.everett’at’vale-anderson.com) from your outlook account. I will then send you a couple of calendar entries from my phone (one all day entry and one timed entry) to your email address in your Finnish timezone. This will then obviously go through my Office 365 Exchange server before ending up on your Sailfish phone. OK, its not the same as creating and looking at the event on the same Sailfish phone, but at least it will be synchronising via an Office365 server running on UTC so it might show up the problem?

@Steve_Everett, can I please ask, are you’re still experiencing this issue?

@flypig Yes, and No. Because of all the issues are with synchronisation of Exchange (Office365) accounts, specifically (and all of which I’ve previously reported as bugs):

  • Accounts fail to sync with errors when network changes from mobile to wireless and vice versa
  • Email auto synchronise just completely stops randomly with no more auto sync until you re-boot
  • Not all email folders are shown, so if I have say 30 email folders on my Exchange accounts, then only 20 of them, seemingly at random, get shown and can be used/accessed when you swipe left to the folder view
  • Calendar issues (i.e. dates later than they should be, all day events spilling over into the next day when they should not be, etc)
  • Contact issues (favourites disappear, duplicates, etc)

I decided I’d had enough as it was just not usable or reliable enough. So all of the above are still happening on XA2 on 4.3 as of last week.

However, having found that Office 365 also supports imap synchronisation I have, last weekend, changed all my Office 365 accounts from Exchange Sync to IMAP sync.

But since Office 365 does not support caldav or carddav I have had to make some other changes as I need both calendar and contacts - and obviously moving from Exchange sync to IMAP sync I have now lost the ability to synchronise my calendar and contacts with Office365. So:

  • I have moved my calendars to my home NAS server (Synology) and now sync calendars with this across all my devices using caldav.
  • I have moved my contacts onto the synology NAS server, but I can’t yet get carddav to work with this. This is probably due to not getting the syntax right on the carddav account on SFOS as it doesn’t seem to be standard across ios, android, windows, linux, etc. And SFOS seems to have a weird combined carddav/caldav account layout which I can’t quite work out yet (eg: if I set the port on the server for caldav, then its not right for carddav and vice versa). So the upshot at the moment is that I have moved all my contacts locally onto SFOS until I can figure carddav out.

The result of all these changes are:

  • IMAP email sync to Office 365 works just fine - no missing folders, no sync errors, auto sync does not fail or stop. In short it works reliably and well.
  • Calendar sync to my NAS server also works reliably and well - entries are at the right time and not one hour late, all day entries are scheduled only for the days they are meant to be, not those days +1
  • Contact favourites work and persist as they should with no duplicates (well obviously, because they are static and not sync’d).

So all is good and the problems have all been ‘resolved’ by these changes - even if it was all a bit of a pain to make them.

Seems to me that the inescapable conclusion, and perhaps why so few forum members have these bugs (because it appears that Exchange is not widely used), is that pretty much all of the above problems come from bugs in the Exchange sync plugin code?

Just as a side note, the time zone on the synology NAS is ‘United Kingdom, London’ - the same as my SFOS XA2.

Also see IMAP Email Setup Bugs on 4.3 as one of the setup issues I had when specifying a peak synchronisation time range for the IMAP email account to Office365 was that, yes, you’ve guessed it, the time range ended up being an hour later than I set it.

So just to clarify this point, as of a couple of weeks ago before you switched to CalDAV, and using 4.3 Suomenlinna, you still experienced Exchange events moving by an hour as a result of a sync?

I want to separate this from all day events spilling over into the next day (which I’m looking into separately). I appreciate it’s tempting to bundle all of the issues together, but when it comes to fixing them, it’s really helpful to keep things isolated.

1 Like

Thanks, that’s really helpful to know. I’ve tried all sorts of Office365 combinations (different server timezones, different device timezones, different event timezones) and haven’t been able to reproduce it, so I must still be missing some crucial aspect. I will persevere.

Understood, thank you!

@flypig Happy to send you a meeting invite from my office365 account to see if it will trigger the issue if that might help. I still have my calendar ‘frozen’ on there since I moved the version I use to the NAS.

1 Like

Thank you for the offer. I’ve sent an email to the address you mentioned earlier. If you could reply back with an invitation, that would be great. Let’s see what happens.

Thank you, the invitation has arrived okay.

Just to follow up on this, we’ve made changes to our Exchange sync code to better handle timezone information on events. Most notably, whereas timezones were being synced only for recurring or all day events, the information is now synced for all events types. The Microsoft to IANA timezone conversion has also been made more robust.

As I’m not able to reproduce the issue on my device/server combination, I can’t be entirely certain that this will address the original issue, but I believe it should help.

At the same time, we also looked at the issue of all day event overhangs (where they cross over into the next day), and all day recurring event exceptions. Both of which should now work correctly.

The changes won’t make it into the next release I’m afraid, but likely the one after.

Thanks @Steve_Everett for your help with this, and for lodging the original report.

4 Likes