I'm trying to enable debug logging for Firebase analytics in Android Studio. I have tried following the instructions found here and still don't see the logs I expect: https://firebase.google.com/docs/analytics/android/events#log_events
When I run the commands described in the link (and shown above) in the terminal within Android Studio this is the output I see:
--------- beginning of system
--------- beginning of crash
--------- beginning of main
05-19 20:14:12.794 I/FA ( 3083): App measurement is starting up, version: 9080
05-19 20:14:12.794 I/FA ( 3083): To enable debug logging run: adb shell setprop log.tag.FA VERBOSE
and this is what is shown in the Android Monitor tab in logcat:
05-19 20:14:12.794 3083-3083/com.nick.app I/FA: App measurement is starting up, version: 9080
05-19 20:14:12.794 3083-3083/com.nick.app I/FA: To enable debug logging run: adb shell setprop log.tag.FA VERBOSE
What I expect to see is an indication the various "events" I have logged are logged correctly. I have seen them in the firebase developer console which leads me to believe I have implemented them properly, I would just like a quicker way to know for testing purposes.
What steps need to be taken to properly view the firebase analytics debug logs?
Make sure you run the adb shell setprop log.tag.FA VERBOSE
and then you restart the app. Enabling logs only works for future logs. If you have more then one device or emulator attached to the computer you might need to tell adb which one you are setting the property for. You can read the current adb properties with adb shell getprop
. You should see log.tag.FA
property set to VERBOSE
. Once you set the log.tag.FA
property it will persist until you restart the device so you only need to do that once after the device reboots.