[Galaxy Tab 2 Q&A, Help & Troubleshooting] n.p.:
P5110 running lineage-13.0-20180107-nightly-espressowifi-signed.zip

I kept running into the endless "waiting for contacts to update" problem (and deleting the data for "contacts storage" did not help). Tried restoring from (app) backups, and the situation just got worse. Now I get an immediate "unfortunately, contacts has stopped" error.

Did a logcat (not an expert at that). This looks relevant:

01-13 18:55:38.666 461 476 I ActivityManager: Start proc 7586:com.android.contacts/u0a6 for activity com.android.contacts/.activities.PeopleActivity
01-13 18:55:38.667 461 505 W art : Long monitor contention event with owner method=void com.android.server.am.BroadcastQueue.processNextBroadcast(boolean) from BroadcastQueue.java:654 waiters=3 for 136ms
01-13 18:55:38.677 461 5810 D ActivityManager: cleanUpApplicationRecord -- 6918
01-13 18:55:38.857 7586 7586 W System : ClassLoader referenced unknown path: /data/app/com.android.contacts-2/lib/arm
01-13 18:55:38.860 7586 7586 D AndroidRuntime: Shutting down VM
01-13 18:55:38.878 7586 7586 E AndroidRuntime: FATAL EXCEPTION: main
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Process: com.android.contacts, PID: 7586
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Theme: themes:{}
01-13 18:55:38.878 7586 7586 E AndroidRuntime: java.lang.RuntimeException: Unable to instantiate application com.android.contacts.ContactsApplication: java.lang.ClassNotFoundException: Didn't find class "com.android.contacts.ContactsApplication" on path: DexPathList[[zip file "/data/app/com.android.contacts-2/base.apk"],nativeLibraryDirectories=[/data/app/com.android.contacts-2/lib/arm, /vendor/lib, /system/lib]]
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.LoadedApk.makeApplication(LoadedApk.java:579)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4724)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.ActivityThread.-wrap1(ActivityThread.java)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1424)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5461)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Caused by: java.lang.ClassNotFoundException: Didn't find class "com.android.contacts.ContactsApplication" on path: DexPathList[[zip file "/data/app/com.android.contacts-2/base.apk"],nativeLibraryDirectories=[/data/app/com.android.contacts-2/lib/arm, /vendor/lib, /system/lib]]
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.Instrumentation.newApplication(Instrumentation.java:982)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.LoadedApk.makeApplication(LoadedApk.java:574)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: ... 9 more
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Suppressed: java.io.IOException: No original dex files found for dex location /data/app/com.android.contacts-2/base.apk
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexFile.openDexFileNative(Native Method)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexFile.openDexFile(DexFile.java:295)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexFile.<init>(DexFile.java:80)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexFile.<init>(DexFile.java:59)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexPathList.loadDexFile(DexPathList.java:279)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexPathList.makePathElements(DexPathList.java:248)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.DexPathList.<init>(DexPathList.java:120)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.BaseDexClassLoader.<init>(BaseDexClassLoader.java:48)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at dalvik.system.PathClassLoader.<init>(PathClassLoader.java:65)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.ApplicationLoaders.getClassLoader(ApplicationLoaders.java:58)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.LoadedApk.getClassLoader(LoadedApk.java:376)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at android.app.LoadedApk.makeApplication(LoadedApk.java:569)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: ... 9 more
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Suppressed: java.lang.ClassNotFoundException: com.android.contacts.ContactsApplication
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.Class.classForName(Native Method)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.BootClassLoader.findClass(ClassLoader.java:781)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: at java.lang.ClassLoader.loadClass(ClassLoader.java:504)
01-13 18:55:38.878 7586 7586 E AndroidRuntime: ... 12 more
01-13 18:55:38.878 7586 7586 E AndroidRuntime: Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack trace available
01-13 18:55:39.125 461 657 W ActivityManager: Force finishing activity com.android.contacts/.activities.PeopleActivity

Yes, indeed, it is not there. I don't see anything in /system/app (isn't contacts supposed to be a system app - TitaniumBackup things so?) either. I have reflashed the rom (without wiping system), and that didn't fix anything, as well.

Does anyone know what is wrong and how to get the contacts app restored and working again?