Forum Xamarin Xamarin.Forms

Xamarin Forms (PCL) w/Android using FCM working in debug mode but not when pulled from Google Play

RonnieCyrierRonnieCyrier USMember ✭✭

I'm really having troubles here. I've successfully implemented FCM in my Xamarin Forms Android App. Everything works in Debug. I get token and token is registered with FCM. I am saving to DB for future use. I also can go to firebase console and send a message and everything works. If i put the app in the Alpha channel on google play, the token is create and saved to database. When I use the console to send a message, my app receives it (OnMessageReceived seems to be called but i cannot be certain) but then I get the error that says "Unfortunately, {App Name} has stopped." Anyone have any ideas.

Target framework is 7.1 supporting 4.4 and above.

I've tried several versions of the manifest Originally with only android.Permission.INTERNET but I've added some extra ones based on some suggestions from several other blogs/support questions.
Here is my current manifest
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="" android:installLocation="auto"
package="" android:versionCode="200165" android:versionName="3.0.0">
<uses-sdk android:minSdkVersion="19" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="" />
<application android:label="APPNAME" android:icon="@drawable/icon">
<receiver android:name="" android:exported="false" />
<receiver android:name="" android:enabled="true" android:exported="true"
<action android:name="" />
<action android:name="" />
<activity android:name=""
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" />

My packages are:
<package id="Xamarin.Firebase.Common" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.Firebase.Iid" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.Firebase.Messaging" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.Forms" version="" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Ads" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Ads.Lite" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Base" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Basement" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Clearcut" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Gass" version="42.1021.1" targetFramework="monoandroid71" />
<package id="Xamarin.GooglePlayServices.Tasks" version="42.1021.1" targetFramework="monoandroid71" />

I would love some help on this. The error message is not very helpful. I'm not 100% sure how to check some logs on the android itself to see what is missing. I've tried LogCat Reader and aLogCat apps to get a better message but I must be doing something wrong there as I'm not getting anything relevant as far as I can tell.

Any ideas? Has anyone gotten a Xamarin.Forms project pushed up to beta working?

Best Answer


Sign In or Register to comment.