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

No data seams to reach Firebase Analytics from the iOS targets. #118

Open
Horsetopus opened this issue May 10, 2022 · 11 comments
Open

No data seams to reach Firebase Analytics from the iOS targets. #118

Horsetopus opened this issue May 10, 2022 · 11 comments

Comments

@Horsetopus
Copy link

Hi,

Describe the bug
No data seams to reach Firebase Analytics from the iOS targets.

To Reproduce
Steps to reproduce the behavior:

  1. following every steps in the instructions (plist is copied at the right place, bundle id is exactly the same)
  2. use logEvent
  3. add the debug flag to launch scheme in Xcode, test on iOs
  4. check the Real time or Debug View
  5. See nothing

Expected behavior
Just as with Android and Web, I should see my activities

Screenshots
Here are the logs of the debugger in Xcode. data seams to be sent.
xcode-logs

Smartphone (please complete the following information):

  • iOs build from capacitor
  • Tested on iOs 15.4 on physical and simulator.

Extra information
For the libraries I think matter:
"@capacitor-community/firebase-analytics": "^1.0.1",
"@capacitor/app": "^1.0.7",
"@capacitor/cli": "^3.3.4",
"@capacitor/core": "^3.3.4",
"@capacitor/ios": "3.3.4"
I use capacitor with vuejs.

Thank you for checking on this, I've been trying for a week to make it work.
Regards

@Elardzhi
Copy link

Same problem

@mtrnik
Copy link

mtrnik commented Jul 1, 2022

Same problem for me

1 similar comment
@hrafnkellbaldurs
Copy link

Same problem for me

@qliqdev
Copy link
Contributor

qliqdev commented Sep 5, 2022

+1 Any ideas?

UPD: Finally Found solution

In your Info.plist file add

<key>FIREBASE_ANALYTICS_COLLECTION_ENABLED</key>
<true/>

@CraigRonald555
Copy link

+1 Any ideas?

UPD: Finally Found solution

In your Info.plist file add

<key>FIREBASE_ANALYTICS_COLLECTION_ENABLED</key>
<true/>

This didn't work for me

@qliqdev
Copy link
Contributor

qliqdev commented Sep 13, 2022

@CraigRonald555 So, you can try this doc

@CraigRonald555
Copy link

@oneclickwebstudio

Sorry, I was being a dumb dumb, I realised after going through the docs, trying to add different packages via xCode etc. etc. that it turns out that I hadn't updated my package.json file.

@basvdijk
Copy link

I ran into the same issue, it turned out that my Adblocking DNS was still enabled and was blocking calls to analytics

@CraigRonald555
Copy link

The debugview seems to be a bit of a nightmare, I notice a few people on the sites like stackoverflow having issues getting their device to consistently be found by the debugview page. These are the steps I used to finally enable DebugView to find my device:

  1. Close the app on the device you’re working on

  2. Go to the Firebase console and sign out of your account

  3. Sign back in again, go to the console and select the project you’re working on.

Again, not sure if this made a difference however do NOT click on DebugView item under the “Project shortcuts” list. Instead, click on the “Analytics” drop-down and select DebugView from there.

  1. It may be possible that this process updates the data stream used in the DebugView page - after following these steps I noticed events which had been missed initially were now showing up - almost as if the event was sent/received properly however the DebugView wasn’t showing the correct data stream.

Bonus tip:

Had issues with this again today, and after signing out/in to Firebase the DebugView still wasn't finding my device. What fixed it was, on my device, move the app into the background i.e. swipe up from the bottom to go to the home screen...

When you re-open the app into the foreground, the DebugView should now start displaying events. I imagine this works because the action of moving the app into the background I believe triggers any saved events on the device to be sent to Firebase, essentially flushing the queue.

@uKioops
Copy link

uKioops commented Oct 20, 2023

I have the same problems. App with two targets, none of them can send data to firebase analytics (DebugView and Dashboard).

I the debug console in Xcode, I have a few messages that indicates this is not working, I've tried for a week every solution that I can find but nothing works. I have no problem getting data with Android on both Flavors.

[FirebaseAnalytics][I-ACS800023] No pending snapshot to activate. SDK name: app_measurement
[FirebaseAnalytics][I-ACS029014] Successfully parsed a configuration. Version: 1697204657512920
[FirebaseAnalytics][I-ACS023016] Analytics is ready to receive events
[FirebaseAnalytics][I-ACS023012] Analytics collection enabled
[FirebaseAnalytics][I-ACS023039] Measurement data sent to network. Timestamp (ms), data: 1697802362834, <APMPBMeasurementBatch: 0x280c458a0>
[GULNetwork postURL:headers:payload:queue:usingBackgroundSession:completionHandler:]: unrecognized selector sent to instance 0x281b28c40
 [FirebaseAnalytics][I-ACS030000] Exception on worker queue. Block ID=APMMeasurement:1683. Exception: 0x0000000102dec4d8 -[APMMeasurement: -[GULNetwork postURL:headers:payload:queue:usingBackgroundSession:completionHandler:]: unrecognized selector sent to instance 0x281b28c40
[FirebaseAnalytics][I-ACS002001] Measurement timer fired
 [FirebaseAnalytics][I-ACS002003] Measurement timer canceled
[FirebaseAnalytics][I-ACS023041] Analytics is uploading but network is not uploading

I believe the last one is the reason I can't get anything outside of the app. But I have no clue where to fix this or why there is problem.

@bhalbritter
Copy link

bhalbritter commented Oct 26, 2023

I am also stuck at the 'Analytics is uploading but network is not uploading' error. Anyone else?

Update:

After some trial and error I got it to work after I updated my pods

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants