FRC Krawler help?

Looking at the FRC Krawler App to evaluate for use in upcoming season.

Got it built and loaded into the emulator, but it stops immediately with this traceback. I suspect we missed some database setup?

E/AndroidRuntime: FATAL EXCEPTION: main
                  Process: com.team2052.frckrawler.development, PID: 2889
                  java.lang.RuntimeException: Unable to start activity ComponentInfo{com.team2052.frckrawler.development/com.team2052.frckrawler.activities.SetupActivity}: java.lang.IllegalStateException: FirebaseApp with name [DEFAULT] doesn't exist. 
                      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
                      at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
                      at android.app.ActivityThread.-wrap11(ActivityThread.java)
                      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
                      at android.os.Handler.dispatchMessage(Handler.java:102)
                      at android.os.Looper.loop(Looper.java:148)
                      at android.app.ActivityThread.main(ActivityThread.java:5417)
                      at java.lang.reflect.Method.invoke(Native Method)
                      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
                   Caused by: java.lang.IllegalStateException: FirebaseApp with name [DEFAULT] doesn't exist. 
                      at com.google.firebase.FirebaseApp.getInstance(Unknown Source)
                      at com.google.firebase.FirebaseApp.getInstance(Unknown Source)
                      at com.google.firebase.database.FirebaseDatabase.getInstance(Unknown Source)
                      at com.team2052.frckrawler.activities.SetupActivity.onCreate(SetupActivity.java:53)
                      at android.app.Activity.performCreate(Activity.java:6237)
                      at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
                      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
                      at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)$@#
                      at android.app.ActivityThread.-wrap11(ActivityThread.java)$@#
                      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)$@#
                      at android.os.Handler.dispatchMessage(Handler.java:102)$@#
                      at android.os.Looper.loop(Looper.java:148)$@#
                      at android.app.ActivityThread.main(ActivityThread.java:5417)$@#
                      at java.lang.reflect.Method.invoke(Native Method)$@#
                      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)$@#
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)$@#

We looked at forking Krawler for our use last year but decided against it. Check your Firebase settings, API keys and app name in Firebase.

Please double check that you have

apply plugin: 'com.google.gms.google-services'

At the bottom of the app build.gradle file and that you have two google-services.json for both the ‘.development’ build and the release build.

To get timely fixes and help, we suggest that you fill out an issue on our GitHub page next time.

Try using an emulator with Google Play Services enabled. It’s failing because it can’t initialize Firebase, a Google app analytics platform.

What’s the specific reason you had to compile it from source anyway? It is also available on the Google Play Store…

It’s open source. Maybe they’re helping development…

Not necessarily. To my knowledge, some teams require more than just what a scouting app provides out of the box and wish to edit the source themselves. However, most would generally be fine with the stock app off the Play Store.

Looks like you answered your question then.

It bothers me that the new firebase stuff requires that those files be present or it won’t even initialize the library (I’d rather it fail softer). That was a pain to sort out after the TBA for Android CI builds stopped working… I eventually made it fail softly on its own.

@OP - if you aren’t sure where to get the google-service.json file, you’ll need to create a Firebase project and configure it to work with your build keys. This page should be able to help.