Duplicate of #190
CALDAV sync fails with Sync thread cancelled! Interrupting sync" and "Couldn't check/increase sequence"
@dd1303 It would be an option, yes.
@devvv4ever attached please find the offending calendar as ICS. I created it with CIE (Calendar Import-Export) and replaced the text for summary, description and location by xxx and also created new UIDs a I saw double values created by CIE. I imported xxx.ICS successfully with CIE to a local Android calendar.
@dd1303 I’ve tried it now, but due to the anonymization radicale can’t import it… Is it possible to create a test account where the original ics is being used? Or alternatively any test account where the error occurs? Otherwise we can’t have a deeper look into it…
@devvv4ever I can create a test account on my radicale server and try to do the initial sync from davx5 to that account with the original ICS. How would you take a look then? Should I send you a davx5-debug.zip again?
@dd1303 18:xx created a new radicale calendar called “xxx”
18:xx created a new davx5 account called “xxx” and assigned the calendar xxx to it
18:xx executed a davx5 sync with the empty calendar, after that the calendar is visible for the Android calendar app
18:26 executed a successful sync with one test entry “test termin” created with my calendar app in calendar xxx
18:54 on Android with Calendar Import-Export loaded the 5548 entries from dd-caldav-2-xxx.ics into calendar xxx
19:00 sync started in davx5 for xxx
19:00:13 radicale output stopped without any sign of processing any calendar entries
19:02:xx davx5 orange activity bar stopped
19:02:12 the known error “[syncadapter.SyncAdapterService] Sync thread cancelled! Interrupting sync” shows up in dav5-log.txt
2020-12-29 19:02:12 7318 [syncadapter.SyncAdapterService] Sync thread cancelled! Interrupting sync 2020-12-29 19:02:12 2 [CustomCertService] CustomCertService destroyed 2020-12-29 19:02:12 7351 [syncadapter.CalendarsSyncAdapterService] Couldn't sync calendars
@dd1303 Oups, I had to many xxx in the continuation lines of dd-caldav-2-xxx.ics. Calendar Import-Export didn’t mind, but when I imported it with Lightning into radicale I saw errors about dtend and dtstart. Attached please find the corrected version dd-caldav-2-xxx2.ics and hopefully this allows you to import it to radicale.
@dd1303 Does the exception appear again when you kill DAVx5 in the task manager and then sync again?
EXCEPTION java.lang.InterruptedException at com.mikepenz.aboutlibraries.R$style.runBlocking(Unknown Source:23) at at.bitfire.davdroid.syncadapter.SyncManager.uploadDirty(SyncManager.kt:2)
It’s some very weird problem that I couldn’t reproduce or understand yet. Probably it’s related to threaded coroutines. Once upon a time, the sync algorithm gets mixed with “com.mikepenz.aboutlibraries.R$style.runBlocking” (which is in no way related to the sync algorithm), and then the sync algorithm code behaves in an undefined way and doesn’t catch the exceptions anymore (although the code is the same and try/catch is there)…
This is why I couldn’t reproduce the problem with your data (thanks btw). It’s not related to the specific event data, but to some other very strange phenomenon.
InterruptedExceptionis normal; Android throws it when synchronization runs too long. But sync should just continue when it’s called again.
@rfc2822 I executed a sync, failed, killed davx5 from the Android apps settings, started davx5, tried the sync again and failed with the same exception.
@dd1303 Hi - do you still follow on this issue and want to fix it? In that case I am willing to support, i.e give it some other tries if required. Otherwise it’s fine with me to close it. I can continue with my workaround: one big static calendar (entries from past until 31.12.2019); plus a smaller one (entries since 1.1.2020 towards future) which is syncing fine.