Cannot open files locally using Collabora Office on Android

I have been unable to open files on Android using Collabora Office (but also LibreOffice Viewer) as long as I can remember. When I click on the file, Collabora Office keeps stopping - this happens for a multitude of Android devices. What I have typically done to work around this, is simply open the Collabora Office app and look for the file by browsing the file system.

I could not find a similar issue using web search and the Nextcloud forum search.

Can anyone point me in the right direction? Are there any logs that could help me pinpoint this issue?

Thanks in advance!

PS: I am on the latest versions of Nextcloud server (27.1.1), Nextcloud client (3.25.0) and Collabora Office (23.05.4.1).

Should be the same issue as described here:
Cannot open Office files via the android app after Nextcloud 27.1 upgrade (and link to bug report)

As I see it right, it still is not fixed. Affected are Nextcloud 24 to 27.

The issue you refer to is not related, as far as I understand.

My issue is not caused by Collabora Online, as I do not have it installed, but rather to opening the file locally with the Collabora Office app on Android.

I am completely new to Nextcloud but i think i have the same problem.
Trying to open files like .xlsx or .docx with the Android app at first was trying to do it with the Google apps, which did not work.
Then i installed the Collabora office app and i get the same behaviour you described, the app would either stop/crash while opening the document or just show the apps start page.

Opening the documents via the browser works (on desktop as well as mobile) but that is not a good solution on mobile…

i am using Nextcloud Hub 6 (27.1.0)

I just wanted to clarify that this behavior cannot be observed when opening the exact same file via another application (e.g. file manager or messenger).

Any hints how to pinpoint this issue? I will gladly open an issue on GitHub…

This issue is a bit annoying when using the Nextcloud app to access my files.

May I ask again about any hints?

Hi! It seems like there may be a compatibility issue with Collabora Office on Android devices. To troubleshoot, check for any error logs in the app or system logs on your device. Additionally, ensure you have the latest updates for Collabora Office, as well as Nextcloud server and client.

Thank you for the input. As suggested, I created a bug report and went through it looking for the exception. What I found was the following, but I am clueless when it comes to Android, so I do not understand what is going on here. Any ideas?

Another thing I just found out: Opening an odt file works flawlessly (same docx converted to odt)

NullPointerException

01-07 20:19:22.740 10258 10604 10604 D LOActivity: SCHEME_FILE: getPath(): /storage/emulated/0/Android/media/com.nextcloud.client/nextcloud/snixx@example.com/Recipes/Rice Salad.docx
01-07 20:19:22.740 10258 10604 10604 D AndroidRuntime: Shutting down VM
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: FATAL EXCEPTION: main
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: Process: com.collabora.libreoffice, PID: 10604
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.collabora.libreoffice/org.libreoffice.androidlib.LOActivity}: java.lang.NullPointerException: Attempt to invoke virtual method ‘boolean java.lang.String.equals(java.lang.Object)’ on a null object reference
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3802)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3942)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:139)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:96)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2448)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:106)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.os.Looper.loopOnce(Looper.java:205)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.os.Looper.loop(Looper.java:294)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:8194)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:971)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: Caused by: java.lang.NullPointerException: Attempt to invoke virtual method ‘boolean java.lang.String.equals(java.lang.Object)’ on a null object reference
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at org.libreoffice.androidlib.LOActivity.canDocumentBeExported(LOActivity.java:1176)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at org.libreoffice.androidlib.LOActivity.initUI(LOActivity.java:345)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at org.libreoffice.androidlib.LOActivity.init(LOActivity.java:255)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at org.libreoffice.androidlib.LOActivity.onCreate(LOActivity.java:248)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.Activity.performCreate(Activity.java:8621)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.Activity.performCreate(Activity.java:8599)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1456)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3784)
01-07 20:19:22.741 10258 10604 10604 E AndroidRuntime: … 12 more
01-07 20:19:22.744 1000 1757 10669 I DropBoxManagerService: add tag=data_app_crash isTagEnabled=true flags=0x2
01-07 20:19:22.744 1000 1757 8328 W ActivityTaskManager: Force finishing activity com.collabora.libreoffice/org.libreoffice.androidlib.LOActivity
01-07 20:19:22.745 10170 2551 2574 V WindowManagerShell: Transition requested: android.os.BinderProxy@22dae6f TransitionRequestInfo { type = 2, triggerTask = null, remoteTransition = null, displayChange = null, flags = 16 }
01-07 20:19:22.750 10258 10604 10604 I Process : Sending signal. PID: 10604 SIG: 9
01-07 20:19:22.766 root 1076 1076 I Zygote : Process 10604 exited due to signal 9 (Killed)
01-07 20:19:22.766 1000 1757 8328 I ActivityManager: Process com.collabora.libreoffice (pid 10604) has died: fg TOP