NumberFormatException in 1.11-ose



  • Hello,

    I recently experience crashes during sync:

    --- BEGIN DEBUG INFO ---
    Account name: [REDACTED]
    Authority: org.dmfs.tasks
    
    EXCEPTION:
    java.lang.NumberFormatException: For input string: ""
    	at java.lang.Integer.parseInt(Integer.java:533)
    	at java.lang.Integer.parseInt(Integer.java:556)
    	at net.fortuna.ical4j.model.property.Priority.setValue(Priority.java:218)
    	at net.fortuna.ical4j.data.CalendarBuilder$ContentHandlerImpl.propertyValue(CalendarBuilder.java:299)
    	at net.fortuna.ical4j.data.CalendarParserImpl$PropertyParser.parse(CalendarParserImpl.java:282)
    	at net.fortuna.ical4j.data.CalendarParserImpl$PropertyParser.access$1100(CalendarParserImpl.java:229)
    	at net.fortuna.ical4j.data.CalendarParserImpl$PropertyListParser.parse(CalendarParserImpl.java:210)
    	at net.fortuna.ical4j.data.CalendarParserImpl$ComponentParser.parse(CalendarParserImpl.java:422)
    	at net.fortuna.ical4j.data.CalendarParserImpl$ComponentParser.access$900(CalendarParserImpl.java:406)
    	at net.fortuna.ical4j.data.CalendarParserImpl$PropertyListParser.parse(CalendarParserImpl.java:208)
    	at net.fortuna.ical4j.data.CalendarParserImpl.parseCalendar(CalendarParserImpl.java:115)
    	at net.fortuna.ical4j.data.CalendarParserImpl.parseCalendarList(CalendarParserImpl.java:180)
    	at net.fortuna.ical4j.data.CalendarParserImpl.parse(CalendarParserImpl.java:149)
    	at net.fortuna.ical4j.data.CalendarBuilder.build(CalendarBuilder.java:198)
    	at net.fortuna.ical4j.data.CalendarBuilder.build(CalendarBuilder.java:178)
    	at at.bitfire.ical4android.Task$Companion.fromReader(Task.kt:66)
    	at at.bitfire.davdroid.syncadapter.TasksSyncManager.processVTodo(TasksSyncManager.kt:149)
    	at at.bitfire.davdroid.syncadapter.TasksSyncManager.processRemoteChanges(TasksSyncManager.kt:138)
    	at at.bitfire.davdroid.syncadapter.SyncManager.performSync(SyncManager.kt:127)
    	at at.bitfire.davdroid.syncadapter.TasksSyncAdapterService$TasksSyncAdapter.sync(TasksSyncAdapterService.kt:63)
    	at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter.onPerformSync(SyncAdapterService.kt:77)
    	at android.content.AbstractThreadedSyncAdapter$SyncThread.run(AbstractThreadedSyncAdapter.java:272)
    
    SOFTWARE INFORMATION
    Package: at.bitfire.davdroid
    Version: 1.11-ose (213) from 14.04.2018
    Installed from: com.google.android.packageinstaller
    JB Workaround installed: no
    
    CONNECTIVITY (at the moment)
    Active connection: WiFi, CONNECTED
    
    CONFIGURATION
    Power saving disabled: yes
    android.permission.READ_CONTACTS permission: granted
    android.permission.WRITE_CONTACTS permission: granted
    android.permission.READ_CALENDAR permission: granted
    android.permission.WRITE_CALENDAR permission: granted
    org.dmfs.permission.READ_TASKS permission: granted
    org.dmfs.permission.WRITE_TASKS permission: granted
    System-wide synchronization: automatically
    Account: [REDACTED]
      Address book sync. interval: 240 min
      Calendar     sync. interval: 60 min
      OpenTasks    sync. interval: 240 min
      WiFi only: false
      [CardDAV] Contact group method: GROUP_VCARDS
      [CalDAV] Time range (past days): 30
               Manage calendar colors: false
    Address book account: [REDACTED]
      Main account: Account {name=[REDACTED], type=bitfire.at.davdroid}
      URL: [REDACTED]
      Sync automatically: true
    
    SQLITE DUMP
    android_metadata
    	|  locale |
    	|  de_DE |
    ----------
    services
    	|  _id | accountName | service | principal |
    	|  1 | [REDACTED] |
    	|  2 | [REDACTED] |
    ----------
    sqlite_sequence
    	|  name | seq |
    	|  services | 2 |
    	|  homesets | 20 |
    	|  collections | 89 |
    ----------
    homesets
    	|  _id | serviceID | url |
    	|  17 | 1 | [REDACTED] |
    	|  18 | 1 | [REDACTED] |
    	|  19 | 2 | [REDACTED] |
    	|  20 | 2 | [REDACTED] |
    ----------
    collections
    [REDACTED]
    ----------
    
    SYSTEM INFORMATION
    Android version: 7.0 (NRD90M.G930FXXS2DRC3)
    Device: samsung SM-G930F (herolte)
    
    --- END DEBUG INFO ---
    

    I'm syncing with Horde Groupware. Has been working flawlessly for over a year. Is there any way for me to find out the offending object?


  • developer

    Unfortunately, I have forgotten to show the resource names for tasks (in contrast to events and contacts). Should be fixed with https://gitlab.com/bitfireAT/davdroid/commit/fd84ff37e5f93d00f4a162ea5d5cd6724b1c0a1f

    Regarding your problem: Sounds like an invalid task file. Please enable debug logs (see screenshot on https://www.davdroid.com/faq/how-to-debug/) and have a look at them. They should contain all necessary information.

    Does this help?



  • The debug log unfortunately did not really help me.

    Interestingly, when I deactivated sync for all 6 task lists (keeping only the address books activated for sync), the problem disappeared. However, regardless which of the task lists I subsequently re-activated, I always got the sync problem. I then purged tasks (within Horde) that had been completed more than 30 days ago -- no more synchronization problems. But current tasks no longer appeared on the smart phone either! Luckily, when I now add new tasks, they appear both on the Android device as well as inside horde.

    So, long story short, did not find the cause of the problem, but was somehow able to solve it (with side effects though -- would have liked to keep the current tasks on my mobile.