Failing sync for Mail, Calendar, Contact of Google accounts
- /e/ version: 1.5
- Device model(s): FP3
- Device rooted: no
Summary
After having upgraded to 1.5 via OTA, my emails, calendar events, and contacts weren't fetched/synchronized anymore. They were working with the previous version 1.4.
My /E/account works fine.
The behavior is similar to the one described in #5793 (closed). I'm not sure though that the cause is the same.
The problem
Steps to reproduce
- Add Google accounts in account settings
- Fetch new email in Mail app for instance
Notice that the synchronization temporarily works just after adding the account
What is the current behavior?
- email, calendar events, and contacts aren't synchronized/fetched
- When going to account (in settings Accounts), and then "Account extra settings", normally you go to the app Account Manager, but you get a black screen.
- Sometimes I get an exception just after adding the account in the account manager.
What is the expected correct behavior?
- emails, calendar events, and contacts are synchronized
- Account Manager works, you can change the setting
Technical informations
Account Manager debut-info.txt
EXCEPTION
java.lang.IllegalArgumentException: Account type not supported
at at.bitfire.davdroid.settings.AccountSettings.<init>(AccountSettings.kt:20)
at at.bitfire.davdroid.syncadapter.SyncUtils.setSyncableFromSettings(SyncUtils.kt:4)
at at.bitfire.davdroid.syncadapter.SyncUtils.updateTaskSync(SyncUtils.kt:11)
at at.bitfire.davdroid.App$onCreate$1.invoke(App.kt:6)
at at.bitfire.davdroid.App$onCreate$1.invoke(App.kt:1)
at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Unknown Source:2)
SOFTWARE INFORMATION
┌────────────────────────────────┬───────────────────┬───────────┬───────────┬───────┐
│ Package │ Version │ Code │ Installer │ Notes │
├────────────────────────────────┼───────────────────┼───────────┼───────────┼───────┤
│ foundation.e.accountmanager │ 4.2.3.3-ose │ 402030300 │ — │ │
│ foundation.e.tasks │ 1.2.3-76-gca2dc61 │ 7800 │ — │ │
│ com.android.providers.contacts │ 11 │ 30 │ — │ │
│ com.android.providers.calendar │ 11 │ 30 │ — │ │
│ foundation.e.calendar │ 11 │ 30 │ — │ │
└────────────────────────────────┴───────────────────┴───────────┴───────────┴───────┘
SYSTEM INFORMATION
Android version: 11 (e_FP3-user 11 RQ3A.211001.001 eng.root.20221028.150953 dev-keys)
Device: Fairphone FP3 (FP3)
Locale(s): [en_US,fr_BE]
Time zone: <redacted>
Internal memory (/data): 36 GB free of 47 GB
logcat.txt
11-24 17:03:03.120 20408 20408 E ActivityThread: Service at.bitfire.davdroid.syncadapter.GoogleContactsSyncAdapterService has leaked ServiceConnection at.bitfire.cert4android.CustomCertManager$newServiceConn$1@4e1f960 that was originally bound here
11-24 17:03:03.120 20408 20408 E ActivityThread: android.app.ServiceConnectionLeaked: Service at.bitfire.davdroid.syncadapter.GoogleContactsSyncAdapterService has leaked ServiceConnection at.bitfire.cert4android.CustomCertManager$newServiceConn$1@4e1f960 that was originally bound here
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:1835)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.app.LoadedApk.getServiceDispatcherCommon(LoadedApk.java:1707)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:1686)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.app.ContextImpl.bindServiceCommon(ContextImpl.java:1819)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.app.ContextImpl.bindService(ContextImpl.java:1749)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.content.ContextWrapper.bindService(ContextWrapper.java:756)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.cert4android.CustomCertManager.<init>(CustomCertManager.kt:10)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.cert4android.CustomCertManager.<init>(CustomCertManager.kt:19)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.HttpClient$Builder._init_$lambda-2(HttpClient.kt:2)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.HttpClient$Builder.$r8$lambda$p_U9yPBBoiT99e5uNH__Ar5nVSk(Unknown Source:0)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.HttpClient$Builder$$ExternalSyntheticLambda0.certManager(Unknown Source:4)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.HttpClient$Builder.build(HttpClient.kt:40)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter$onPerformSync$1$httpClient$1.invoke(SyncAdapterService.kt:1)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter$onPerformSync$1$httpClient$1.invoke(SyncAdapterService.kt:2)
11-24 17:03:03.120 20408 20408 E ActivityThread: at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:5)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.GoogleContactsSyncAdapterService$ContactsSyncAdapter.sync(GoogleContactsSyncAdapterService.kt:18)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter$onPerformSync$1.invoke(SyncAdapterService.kt:5)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter$onPerformSync$1.invoke(SyncAdapterService.kt:1)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.ConcurrentUtils.runSingle(ConcurrentUtils.kt:2)
11-24 17:03:03.120 20408 20408 E ActivityThread: at at.bitfire.davdroid.syncadapter.SyncAdapterService$SyncAdapter.onPerformSync(SyncAdapterService.kt:3)
11-24 17:03:03.120 20408 20408 E ActivityThread: at android.content.AbstractThreadedSyncAdapter$SyncThread.run(AbstractThreadedSyncAdapter.java:354)
Solutions
Workaround
This workaround works only for a limited time. After some time, the synchronization fails again.
- Remove account
- Clear storage & cache of Account Manager
- Add account
Possible fixes