Skip to content

No receive event anymore on Android with plugin @segment/analytics-react-native-plugin-advertising-id #1092

Description

@renanbronchart

Just as an FYI for anyone looking for a fix for this issue.

I've updated to RN 0.76 and my events were not being sent on Android.
I was using the @segment/analytics-react-native-plugin-advertising-id plugin, version 1.3.5.
Updating to remove the plugin, fixed it. SO it's bound to be a problem on this package @segment/analytics-react-native-plugin-advertising-id plugin

  • analytics-react-native version: 2.21.2
  • Integrations versions (if used):
    "@segment/analytics-react-native": "^2.21.2",
    "@segment/analytics-react-native-plugin-advertising-id": "^1.3.5",
    "@segment/analytics-react-native-plugin-amplitude-session": "^0.4.1",
    "@segment/analytics-react-native-plugin-appsflyer": "0.8.0",
    "@segment/analytics-react-native-plugin-firebase": "^0.4.3",
    "@segment/analytics-react-native-plugin-idfa": "^0.7.2",
    "@segment/sovran-react-native": "^1.1.3",
  • React Native version: "react-native": "0.76.9",
  • iOS or Android or both? Android

Steps to reproduce
Add segmentClient.add({ plugin: new AdvertisingIdPlugin() }); in your code.

Expected behavior
Receive events on segment.

Actual behavior
I didn't receive event anymore on segment with Android.

Activity

  1. sunitaprajapati89 commented on Aug 27, 2025

    @sunitaprajapati89
    Contributor

    @renanbronchart : We tried to reproduce this with example application provided in github repo. It's working fine. See below screenshots

    Image Image Image

    Please check below things at your end

    • You have added right permission in AndroidManifest.xml
    • added right dependency in build.gradle file
  2. renanbronchart commented on Aug 27, 2025

    @renanbronchart
    Author

    Hey @sunitaprajapati89 , thanks for your reply.
    What I'm supposed to add in AndroidManifest.xml and build.gradle file?
    I've never changed anything of the configuration. All worked good before upgrade of ReactNative.
    And now, after the upgrade to 0.76.9, there is a problem with Advertising plugin.

  3. sunitaprajapati89 commented on Aug 27, 2025

    @sunitaprajapati89
    Contributor

    @renanbronchart : The issue with the Advertising ID not working after upgrading to React Native 0.76.9 could stem from several factors, particularly related to changes in the Android platform, React Native’s new architecture, or library-specific configurations.

    Please do following at your end and see if it works

    • Add <uses-permission android:name="com.google.android.gms.permission.AD_ID"/> in AndroidManifest.xml
    • Add implementation 'com.google.android.gms:play-services-ads-identifier:18.2.0' under dependencies in android/app/build.gradle

    Also, please go through this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugBug fix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions