indicator-datetime list evolution calendar all day event a day before actual date of event

Bug #1261191 reported by Pasi Tarhonen
24
This bug affects 4 people
Affects Status Importance Assigned to Milestone
indicator-datetime (Ubuntu)
Confirmed
High
Unassigned

Bug Description

1. What is expected

I add new all day events to evolution calendar (caldav sync with owncloud and also local calendar). Evolution shows events just OK and indicator-datetime calendar shows correct day as bold as well and should also list events below as defined.

2. What actually happens

Indicator-datetime lists events to take place one day ahead e.g. all day event on Monday is listed to be happen on Sunday.
---
ApportVersion: 2.0.1-0ubuntu17.6
Architecture: amd64
DistroRelease: Ubuntu 12.04
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
MarkForUpload: True
NonfreeKernelModules: wl
Package: indicator-datetime 0.3.94-0ubuntu2
PackageArchitecture: amd64
ProcVersionSignature: Ubuntu 3.11.0-15.23~precise1-generic 3.11.10
Tags: precise running-unity third-party-packages
Uname: Linux 3.11.0-15-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm admin debian-tor dialout dip libvirtd lpadmin plugdev sudo syslog

Revision history for this message
Pasi Tarhonen (pasi-tarhonen) wrote :

This behavior is wrong on Ubuntu 12.04, but on 13.10 indicator-datetime lists hole day events correctly.

Revision history for this message
Pasi Tarhonen (pasi-tarhonen) wrote : Dependencies.txt

apport information

tags: added: apport-collected precise running-unity third-party-packages
description: updated
Revision history for this message
Pasi Tarhonen (pasi-tarhonen) wrote : ProcEnviron.txt

apport information

description: updated
summary: - indicator-datetime shows hole day evolution calendar events a day ahead
+ indicator-datetime shows evolution calendar all day events a day ahead
summary: - indicator-datetime shows evolution calendar all day events a day ahead
+ indicator-datetime list evolution calendar all day events a day ahead
summary: - indicator-datetime list evolution calendar all day events a day ahead
+ indicator-datetime list evolution calendar all day events a day before
summary: indicator-datetime list evolution calendar all day events a day before
+ actual time
summary: - indicator-datetime list evolution calendar all day events a day before
- actual time
+ indicator-datetime list evolution calendar all day event a day before
+ actual date of event
Charles Kerr (charlesk)
Changed in indicator-datetime (Ubuntu):
importance: Undecided → Medium
status: New → In Progress
status: In Progress → New
importance: Medium → Undecided
Charles Kerr (charlesk)
summary: indicator-datetime list evolution calendar all day event a day before
- actual date of event
+ actual date of event in 12.04
Revision history for this message
Sebastien Bacher (seb128) wrote :

That's still an issue on xenial, all days event from google calendar are listed the day before. Having for example the patch pilot calendar enable and opening the indicator doesn't list the persons registered for today but the names for tomorrow with "Tomorrow 00:00" next to them

summary: indicator-datetime list evolution calendar all day event a day before
- actual date of event in 12.04
+ actual date of event
Changed in indicator-datetime (Ubuntu):
importance: Undecided → High
tags: added: rls-x-incoming
Changed in indicator-datetime (Ubuntu):
status: New → Confirmed
Revision history for this message
Sebastien Bacher (seb128) wrote :

The issue where "Tomorrow 00:00" is displayed instead of "Tomorrow" can be fixed by changing src/utils.c generate_full_format_string_at_time()

        const gboolean full_day = then_end && (g_date_time_difference(then_end, then) >= G_TIME_SPAN_DAY);

to

        const gboolean full_day = then_end && (g_date_time_difference(then_end, then) >= G_TIME_SPAN_DAY || g_date_time_difference(then_end, then) == 0);

seems like the day event don't have a DTEND and that the code consider that they start and end at the same time. Either we should consider a length=0 as full day or we should fix the code to set "end" to a different value if that case

Revision history for this message
Charles Kerr (charlesk) wrote :

If the denote-full-day-event-with-DTEND-equals-DTSTART idiom is commonplace I guess we could modify utils.c to follow that idiom, but (a) do we actually know that's the case in this bug and (b) if so, do other calendar systems honor it as well?

It would be helpful to see the actual .ics entry related to the event causing this behavior.

Specifying DTSTART and DTEND to the same time in a calendar component is a spec violation, at least according to http://www.kanzaki.com/docs/ical/dtend.html

Revision history for this message
Sebastien Bacher (seb128) wrote :

@Charles

I don't know if that "idiom is commonplace" but at least the patch pilot calendar [1] as such events and the google UI/evolution/gnome-calendar correctly list them as day event

I've exported the ICS and events have that format

"BEGIN:VEVENT
DTSTART;VALUE=DATE:20160118
DTSTAMP:20160112T165350Z
...
CREATED:20151211T075059Z
DESCRIPTION:Pilot <name>
SUMMARY:Pilot <name>
...
END:VEVENT"

AS you can see there is only a DTSTART, http://www.kanzaki.com/docs/ical/vevent.html states

"For cases where a "VEVENT" calendar component specifies a "DTSTART" property with a DATE data type but no "DTEND" property, the events non-inclusive end is the end of the calendar date specified by the "DTSTART" property"

So to reply to your questions

a) The missing DTEND is a valid case and the code doesn't handle it well
b) other systems honor it

[1] https://calendar.google.com/calendar/embed?<email address hidden>&gsessionid=OK

Revision history for this message
Charles Kerr (charlesk) wrote :

Ok, this looks like real progress to me. This means we should be able to create ical input along the lines of seb128's snippet in comment #8 and keep feeding it into indicator-datetime's regression tests until we see where the problem is.

First guess is that indicator-datetime's code is somehow injecting an incorrect endpoint, but we'll see.

Changed in indicator-datetime (Ubuntu):
assignee: nobody → Charles Kerr (charlesk)
Revision history for this message
Khurshid Alam (khurshid-alam) wrote :

The issue still reproducible on zesty.

Revision history for this message
Roascio Paolo (roa) wrote :

I have similar behaviour on ubuntu touch since OTA-13 (vivid), but i don't know if this bug involves also phones or it's another story. However in my tests (with google calendar) i found this:

a) if i set an event with defined time (eg. from 09:00 am to 10:00 am) indicator works always as expected;

b) if i add an event for the whole day (one shot) indicator reports correct date and time 00:00;

c) if i add an event for the whole day yearly repeated (eg. birthday), indicator reports wrong values, always a day ahead, with this particularity:
   - If notification is turned off the time is 00:00;
   - If notification is set (any value), the time is always 02:00 am

If i tap on the wrong date, calendar opens on (indeed) the wrong date, which doesn't have events registered, but in calendar and in agenda events are correctly registered.

Analyzing the ical file for both b) and c) cases, i can see that the only difference between the two files is the RRULE:FREQ=YEARLY statement.

ical snippet for case b) is:

DTSTART;VALUE=DATE:20170413
DTEND;VALUE=DATE:20170414

ical snippet for case c) is:

DTSTART;VALUE=DATE:20170413
RRULE:FREQ=YEARLY
DTEND;VALUE=DATE:20170414

Maybe it's a different case, but i have both DTSTART and DTEND correctly(?) set. It seems that there is something wrong in parsing the RRULE statement. I tried also to play with google parameters, but the only that highlights the problem is the repetition of an event. Doesn't indicator expects the DTEND closely after DTSTART in the ical file?

Changed in indicator-datetime (Ubuntu):
assignee: Charles Kerr (charlesk) → nobody
Revision history for this message
huizache (huizache) wrote :

This is still an issue on Ubuntu-Mate Jammy 22.04.1

Calendar notification one day ahead for all day events.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.