Tasks sync not working with Kolab server

  • Every time when the app wants to sync with my Kolab account, it fails because of the following problem (I don’t know if the sync is the problem, or if something is already stored not correct on the device), I am using the latest versions of DAVDroid and openTasks from Google Play, sync of Contacts and Calendar is working as expected:

    Synchronization phase: 4
    Account name: KolabNow Tasks
    Authority: org.dmfs.tasks
    java.text.ParseException: Unparseable date: "INTERVAL=1;BYMONTH=1;BYDAY=1FR" (at offset 0)
    at java.text.DateFormat.parse(DateFormat.java:579)
    at net.fortuna.ical4j.model.DateTime.setTime(DateTime.java:414)
    at net.fortuna.ical4j.model.DateTime.<init>(DateTime.java:344)
    at net.fortuna.ical4j.model.DateList.<init>(DateList.java:134)
    at at.bitfire.ical4android.DateUtils.androidStringToRecurrenceSet(DateUtils.java:170)
    at at.bitfire.ical4android.AndroidTask.populateTask(AndroidTask.java:215)
    at at.bitfire.davdroid.resource.LocalTask.populateTask(LocalTask.java:64)
    at at.bitfire.ical4android.AndroidTask.getTask(AndroidTask.java:85)
    [wrapped] at.bitfire.ical4android.CalendarStorageException: Couldn't parse locally stored event
    at.bitfire.ical4android.CalendarStorageException: Couldn't parse locally stored event
    at at.bitfire.ical4android.AndroidTask.getTask(AndroidTask.java:92)
    at at.bitfire.davdroid.resource.LocalTaskList.getDirty(LocalTaskList.java:93)
    at at.bitfire.davdroid.syncadapter.SyncManager.uploadDirty(SyncManager.java:320)
    at at.bitfire.davdroid.syncadapter.SyncManager.performSync(SyncManager.java:159)
    at at.bitfire.davdroid.syncadapter.TasksSyncAdapterService$SyncAdapter.onPerformSync(TasksSyncAdapterService.java:63)
    at android.content.AbstractThreadedSyncAdapter$SyncThread.run(AbstractThreadedSyncAdapter.java:259)
    DAVdroid version: (87) Sat Jan 02 11:24:54 MEZ 2016
    Installed from: com.android.vending
    JB Workaround installed: no
    System-wide synchronization: automatically
    Account: konrad.renner@kolabserver.at
      Address book sync. interval: —
      Calendar     sync. interval: 1440 min
      OpenTasks    sync. interval: —
    Account: KolabNow Kontakte
      Address book sync. interval: 1440 min
      Calendar     sync. interval: —
      OpenTasks    sync. interval: —
    Account: KolabNow Tasks
      Address book sync. interval: —
      Calendar     sync. interval: —
      OpenTasks    sync. interval: 1440 min
    Android version: 5.1.1 (LMY48T)
    Device: LGE Nexus 4 (mako)
  • developer

    @konradrenner Seems like the VTODO is wrong (e.g., RDATE instead of RRULE).

  • @rfc2822 is it a problem in the app or on the server side?

  • developer

    @konradrenner Seems like the VTODO is wrong, so at server (or user) side.

  • @rfc2822 but it occurs when an edited task gets uploaded… Not when a task is downloaded

  • developer


    [wrapped] at.bitfire.ical4android.CalendarStorageException: Couldn’t parse locally stored event

    Looks like a locally stored task is invalid. The lines around AndroidTask.java:215 (DAVdroid are:

    String exDate = values.getAsString(Tasks.EXDATE);
    if (exDate != null)
        task.getExDates().add((ExDate)DateUtils.androidStringToRecurrenceSet(exDate, ExDate.class, allDay));

    So there seems to be a value that can’t be parsed (INTERVAL=1;BYMONTH=1;BYDAY=1FR) in the Tasks.EXDATE column.

    The question is: How could the invalid value find its way into the EXDATE column? Because it’s a dirty (not a new) contact you’re uploading, I guess that the invalid value has been downloaded from the server before, and then written into the EXDATE column.

    This is why I guess the VTODO is wrong, and has been sent by the server incorrectly. However, I’m afraid that validation of my theory will require verbose logs of the initial VTODO download, comprising the VTODO content.

  • developer

    AndroidTask.java L342:

    if (task.rRule != null)
        builder.withValue(Tasks.EXDATE, task.rRule.getValue());

    Seems like the rRule is written into EXDATE… so this is an ical4android problem and will be fixed in next DAVdroid release.

    Thanks for the report.

  • @rfc2822 thanks for fixing it! Can’t wait for it 😉

  • @rfc2822 do I have to delete local data and resync after the Problem is fixed or will it work without deleting an readding the account?

  • developer

    @konradrenner In the meanwhile, it should be enough to delete the task on your mobile phone and then sync. Then create the task again on the mobile phone.

Similar topics

  • 24
  • 9
  • 5