hansemannn / titanium-firebase-core

Use the Firebase Core SDK in the Titanium SDK 🚀
Other
31 stars 23 forks source link

Android - App Crash on Open #47

Closed ulissesrsilva closed 5 years ago

ulissesrsilva commented 5 years ago

Hello! Using Firebase-Core 5.0.0, APPC SDK 8.1.0.GA and PlayServices 16.1.4, the app crashes and doesn't even open, so there's no log or information. Help please 🙏

m1ga commented 5 years ago

If the app doesn't open and you can't provide a log then it could be everything and might not be related to the module. Which module are you trying to use at the end? Only firebase-core? Or do you have a different module included? You can see log even from apps that don't start up (otherwise it would be hard to find those errors). So either start with --log-level trace or check the normal adb logcat for information. If it is a crash there will be some log.

ulissesrsilva commented 5 years ago

Its just firebase-core. I created a new app using appc ti create, installed firebase.core and that's it. If I take firebase.core out, then the apps opens normally.

m1ga commented 5 years ago

my steps:

m1ga commented 5 years ago

The Slack tip with removing play-services-ads-lite-17.2.0.aar from the ti.playservice lib folder is the solution. I did that globally so I wasn't aware that is is missing. You will see the following log btw:

08-20 17:32:03.066 21652 21652 E AndroidRuntime: java.lang.RuntimeException: Unable to get provider com.google.android.gms.ads.MobileAdsInitProvider: java.lang.IllegalStateException: 
08-20 17:32:03.066 21652 21652 E AndroidRuntime: 
08-20 17:32:03.066 21652 21652 E AndroidRuntime: ******************************************************************************
08-20 17:32:03.066 21652 21652 E AndroidRuntime: * The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers    *
08-20 17:32:03.066 21652 21652 E AndroidRuntime: * should follow the instructions here: https://goo.gl/fQ2neu to add a valid  *
08-20 17:32:03.066 21652 21652 E AndroidRuntime: * App ID inside the AndroidManifest. Google Ad Manager publishers should     *
08-20 17:32:03.066 21652 21652 E AndroidRuntime: * follow instructions here: https://goo.gl/h17b6x.                           *
08-20 17:32:03.066 21652 21652 E AndroidRuntime: ******************************************************************************
08-20 17:32:03.066 21652 21652 E AndroidRuntime: 
08-20 17:32:03.066 21652 21652 E AndroidRuntime: 
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread.installProvider(ActivityThread.java:6144)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread.installContentProviders(ActivityThread.java:5704)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5643)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread.-wrap2(ActivityThread.java)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1573)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.os.Handler.dispatchMessage(Handler.java:102)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.os.Looper.loop(Looper.java:173)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at android.app.ActivityThread.main(ActivityThread.java:6459)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at java.lang.reflect.Method.invoke(Native Method)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:938)
08-20 17:32:03.066 21652 21652 E AndroidRuntime:        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:828)

if you check adb logcat when you open the app. Just so you know what to look for