We have moved to a new Sailfish OS Forum. Please start new discussions there.
2

[Solved] Calendar is empty

asked 2016-11-28 09:43:46 +0300

Yenya gravatar image

updated 2016-11-28 18:51:48 +0300

Today I discovered that my calendar is completely empty - no events at all. I have checked that the synchronization account reports no errors, and that the synchronized calendar is enabled in the "Manage calendars" menu. I verified that other places I synchronize this calendar with work without problem. Even when I create a new event on my Jolla phone, it gets propagated to the server, and synchronized to other clients (two instances of Evolution).

When I close the Calendar app and open it again, the newly created event is displayed for a few seconds, and then it also disappears and is replaced by the "Your schedule is free" message. It remains visible in Evolution, as expected.

When I force the synchronizoation from the Calendar app pulley menu, I see the following requests in the access_log of my HTTP server:

jolla.ip.addr - - [28/Nov/2016:08:31:45 +0100] "REPORT /cal/cal.php/calendars/kas/default/ HTTP/1.1" 401 292 "-" "Mozilla/5.0"
jolla.ip.addr - - [28/Nov/2016:08:31:45 +0100] "REPORT /cal/cal.php/calendars/kas/default/ HTTP/1.1" 200 1980 "-" "Mozilla/5.0"

So it seems the authentication is OK (the second request), but Jolla decided that there are no changes to pull, or even that the calendar is empty.

FWIW, my calendar server is Baikal, and I have been using it for the last year or so with Evolution and Jolla without a problem. I have Jolla 1 with 2.0.5.6 Haapajoki OS.

Can you help me where to get more logs or debugging information? Thanks!

edit retag flag offensive close delete

Comments

You may give a look at this SailfishOS wiki page. It will tell you how to obtain more verbose logs.

Don't hesitate to report here.

Damien Caliste ( 2016-11-28 10:00:37 +0300 )edit

I have a similar problem, the calendar is loading for a very long time - about 1 minute sometimes. Using Fruux sync.

Aslanex ( 2016-11-28 10:56:03 +0300 )edit

@Damien_Calliste: thanks for the reply. The problem is that the REPORT request dies with a PHP exception - the request contains something that Baikal does not expect. The relevant part of the trace is here - the request:

Nov 28 11:39:54 Sailfish caldav-client[14400]: [D] Request::debugRequest:140 - "Request : REPORT" 
Nov 28 11:39:54 Sailfish caldav-client[14400]: [D] Request::debugRequest:140 - "<c:calendar-query xmlns:d="DAV:" xmlns:c="urn:ietf:params:xml:ns:caldav"><d:prop><d:getetag /></d:prop><c:filter><c:comp-filter name="VCALENDAR"><c:comp-filter name="VEVENT"> <c:time-range start="20160528T103954Z" end="20171128T103954Z"  /></c:comp-filter></c:comp-filter></c:filter></c:calendar-query>"

and the response:

Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "REPORT response data:<pre>ErrorException: Array to string conversion in /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/CalendarQueryValidator.php:62" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "Stack trace:" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#0 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/CalendarQueryValidator.php(62): Baikal\Framework::exception_error_handler(8, 'Array to string...', '/var/www/html/c...', 62, Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#1 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/CalendarQueryValidator.php(41): Sabre\CalDAV\CalendarQueryValidator->validateCompFilters(Object(Sabre\VObject\Component\VCalendar), Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#2 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/Backend/AbstractBackend.php(150): Sabre\CalDAV\CalendarQueryValidator->validate(Object(Sabre\VObject\Component\VCalendar), Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#3 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/Backend/PDO.php(680): Sabre\CalDAV\Backend\AbstractBackend->validateFilterForObject(Array, Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#4 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/Calendar.php(372): Sabre\CalDAV\Backend\PDO->calendarQuery('1', Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#5 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/Plugin.php(591): Sabre\CalDAV\Calendar->calendarQuery(Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#6 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/CalDAV/Plugin.php(265): Sabre\CalDAV\Plugin->calendarQueryReport(Object(DOMDocument))" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#7 [internal function]: Sabre\CalDAV\Plugin->report('{urn:ietf:param...', Object(DOMDocument), 'calendars/kas/d...')" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#8 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/DAV/Server.php(433): call_user_func_array(Array, Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#9 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/DAV/Server.php(1063): Sabre\DAV\Server->broadcastEvent('report', Array)" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#10 [internal function]: Sabre\DAV\Server->httpReport('calendars/kas/d...')" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#11 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/DAV/Server.php(474): call_user_func(Array, 'calendars/kas/d...')" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#12 /var/www/html/cal/vendor/sabre/dav/lib/Sabre/DAV/Server.php(214): Sabre\DAV\Server->invokeMethod('REPORT', 'calendars/kas/d...')" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#13 /var/www/html/cal/cal.php(82): Sabre\DAV\Server->exec()" 
Nov 28 11:39:55 Sailfish caldav-client[14400]: [D] Request::debugReply:154 - "#14 {main}<pre>"

The relevant part of the CalendarQueryValidator.php around line 62 is this:

protected function validateCompFilters(VObject\Component $parent, array $filters) {

foreach($filters as $filter) {

    $isDefined = isset($parent->$filter['name']); <---- here is the line 62 where it dies

    if ($filter['is-not-defined']) {

Can you tell where the problem is?

Yenya ( 2016-11-28 12:44:28 +0300 )edit

After first boot with 2.0.5.6 I also experienced with calendar problem (all events disappeared, on all my 3 devices jolla1/C and tablet). Simple test as user: timedclient-qt5 -L show me error. Reboot devices fixed this... At least for last 2 days... I still check it every day...
P.S. just now checked it again and again see this problem: nemo@Jolla_C ~]$ timedclient-qt5 -L [W] cookies_get:947 - 'query' call failed: QDBusError("org.freedesktop.DBus.Error.NoReply", "Did not receive a reply. Possible causes include: the remote application did not send a r eply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.") [nemo@Jolla_C ~]$

Schturman ( 2016-11-28 14:39:05 +0300 )edit

@schturman: I have rebooted my Jolla since upgrading several times, so this is definitely not the case. My problem is probably new event types: the latest version of Baikal (which I don't have yet) mentions the following in their https://github.com/fruux/Baikal/releases:

Now allows creation of calendars that contain VJOURNAL, VTODO and VEVENT.

If Sawfish Haapajoki uses VEVENT (and the above trace suggests so), it might be the problem I observe.

Yenya ( 2016-11-28 15:03:39 +0300 )edit

2 Answers

Sort by » oldest newest most voted
0

answered 2016-11-28 10:43:19 +0300

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

updated 2016-11-28 10:43:19 +0300

poddl gravatar image

I had this behavior several times. Waiting for a vew hours fixed it...

edit flag offensive delete publish link more
0

answered 2016-11-28 18:51:08 +0300

Yenya gravatar image

OK, I have upgraded Baikal from 0.2.5 to 0.4.6, and it fixed the problem.

A possible reason was bad interaction of Baikal 0.2.5 with PHP7, which was previously reported here. I am not completely sure, though, because Android clients worked even after the upgrade of the system to PHP7.

Anyway, big thanks to @Damien_Calliste for pointing me to the right direction.

edit flag offensive delete publish link more

Comments

Good that it's working again, you're welcomed !

My guess for Android and Evolution to work before the upgrade was that they format their request a bit differently and they don't pass through the same code path than what happens with the CalDAV client in Sailfish.

Damien Caliste ( 2016-11-29 10:00:26 +0300 )edit

I guess they don't use the nested ccomp-filters:

<c:comp-filter name="VCALENDAR"><c:comp-filter name="VEVENT">

Also, I think it is probably a bug in Sailfish synchronization that it treats the incorrectly formated response to the REPORT request as an empty calendar instead of an error.

In fact, the error reporting or even progress reporting of the Sailfish synchronization is close to non-existent. Even if I force the synchronization by selecting the account in the Settings app and pressing "sync", there is no visual feedback whether the synchronization started at all, or what is the progress or result.

Yenya ( 2016-11-29 10:30:51 +0300 )edit

I think it is probably a bug in Sailfish synchronization that it treats the incorrectly formated response to the REPORT request as an empty calendar instead of an error.

That's right, I've opened a MER bug to follow this issue

Damien Caliste ( 2016-11-29 11:36:29 +0300 )edit
Login/Signup to Answer

Question tools

Follow
1 follower

Stats

Asked: 2016-11-28 09:43:46 +0300

Seen: 609 times

Last updated: Nov 28 '16