luelista/friendica-for-android

Force Close on startup : missing com.google.android.gsf

Opened this issue · 4 comments

After the first run, the app Force Closes immediately on startup. The log starting the HomeActivity generates an exception that the device does not have package : com.google.android.gsf

This is running on CyanogenMod 7.0 without any Google apps installed.

App was downloaded from the F-Droid store ( https://f-droid.org/ )

I have a similar issue:
The app is running If started the first time after installing. But after closing it will not start again. I only get a "unfortunately, Friendica has stopped". After that I can reinstall and reconifgure and it will run one time again.

Hi,
that's caused by a reference in the app to google's cloud messaging service. Even if it's not used later on, it is called once if a user is already logged in while starting the app.

One could easily fix that problem by checking for the availability of the gcm library in HomeActivity.java, line 83.
I'd do it myself but I'm a bit busy atm.

Edit: Even a try-catch statement might be enough... I'll give it a try

Indeed. I got a friendica-debug.apk with deactivated googlecode today. With this version I do not have any problems. Would be great to have a google-free versoin on f-droid, too.

I created a version with a try-catch around the GCM init part. You might try that version and tell me if it works as I don't have a device without google apps.