Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: analytics not working on android #369

Closed
4 of 13 tasks
MitchellPeck opened this issue Apr 22, 2023 · 3 comments
Closed
4 of 13 tasks

bug: analytics not working on android #369

MitchellPeck opened this issue Apr 22, 2023 · 3 comments
Labels

Comments

@MitchellPeck
Copy link

MitchellPeck commented Apr 22, 2023

Plugin(s)

  • Analytics
  • App
  • App Check
  • Authentication
  • Crashlytics
  • Cloud Messaging
  • Performance
  • Remote Config

Did you test the latest version?

  • I use the latest version

Platform(s)

  • Android
  • iOS
  • Web

Current behavior

Analytics sends data when I open the app in a web browser, even on an Android device. But when I open the app on an Android device, no data is sent.

Expected behavior

Data should be sent from the Android device when I open the app on said Android device.

Reproduction

https://github.com/MitchellPeck/bug-analytics-not-working-on-android

Steps to reproduce

1Export the app for android
2Open the app on an android device
3Check that analytics data hasn't been sent

Other information

No response

Capacitor doctor

💊 Capacitor Doctor 💊

Latest Dependencies:

@capacitor/cli: 4.7.3
@capacitor/core: 4.7.3
@capacitor/android: 4.7.3
@capacitor/ios: 4.7.3

Installed Dependencies:

@capacitor/cli: 4.7.0
@capacitor/android: 4.7.0
@capacitor/ios: 4.7.0
@capacitor/core: 4.7.0

[success] Android looking great! 👌

Before submitting

  • I understand that incomplete issues (e.g. without reproduction) are closed.
@MitchellPeck MitchellPeck added bug/fix Something isn't working needs: triage labels Apr 22, 2023
@robingenz
Copy link
Member

Thank you for your request. I will have a look as soon as possible.

@robingenz
Copy link
Member

I tested it myself and also had difficulties with Android at first. But in the end it was only because the app had transferred the events only after a few hours. The next day I had all events in Google Analytics.
From the Firebase documentation:

Generally, events logged by your app are batched together over the period of approximately one hour and uploaded together. This approach conserves the battery on end users’ devices and reduces network data usage.

But for debugging there is the option to activate the Debug Mode. With this I was able to follow the events live.

grafik

@MitchellPeck
Copy link
Author

Awesome, thank you so much!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants