Code Monkey home page Code Monkey logo

react-native-flurry-sdk's Introduction

React Native Flurry SDK (react-native-flurry-sdk)

npm platform licence

A React Native plugin for Flurry SDK

  • Tutorial and sample project are now available at https://github.com/flurry/React-Native-Tutorial.
  • Flurry Push for messaging and Flurry Config for remote configuration are now supported by our plugin!
  • If you are using Apple Xcode < 12, please use release v6.3.0.
  • If you are using React Native < 0.60, please use release v6.0.9.

Table of contents

Installation

  1. Install Flurry SDK module by npm

    npm install react-native-flurry-sdk --save
  2. If you are using React Native >= 0.60, install CocoaPods dependency

    cd ios && pod install && cd ..

    If you are using React Native < 0.60, link React Native dependency

    react-native link react-native-flurry-sdk
  3. Add Flurry JS code

    import Flurry from 'react-native-flurry-sdk';

Android

  • By default, Flurry adds INTERNET and ACCESS_NETWORK_STATE permissions to optimize analytics data. Please see Manual Flurry Android SDK Integration for the other recommended options.

  • To improve analytics identities, please see Manual Flurry Android SDK Integration for adding Google Play Services library in your app by including the following in your build.gradle file:

    dependencies {
        // Recommended to add Google Play Services
        implementation 'com.google.android.gms:play-services-ads-identifier:17.1.0'
    }
  • Flurry Push
    In order to use Flurry Push for Android, please follow the additional steps below:

    1. Follow Set up a Firebase Cloud Messaging client app on Android. Complete "Set up Firebase and the FCM SDK" step for adding Firebase to your Android project. There should be a file google-services.json in your project's android/app folder now. You do not need to provide any setup codes here. Your build.gradle will look like:

         // android/build.gradle (project-level)
         buildscript {
             dependencies {
                 classpath 'com.google.gms:google-services:4.3.10'
             }
         }
         // android/app/build.gradle (app-level)
         apply plugin: 'com.google.gms.google-services'
      
         dependencies {
             implementation 'com.google.firebase:firebase-messaging:21.1.0'
         }
    2. If you want to customize Flurry Push notification, please do the Flurry setup in MainApplication.onCreate(). With the same APIs as the JavaScript version.

      import com.flurry.android.reactnative.FlurryModule;
      
      public class MainApplication extends Application implements ReactApplication {
      
        @Override
        public void onCreate() {
          super.onCreate();
      
          new FlurryModule.Builder()
            .withCrashReporting(true)
            .withLogEnabled(true)
            .withLogLevel(Log.VERBOSE)
            .withReportLocation(true)
            .withMessaging(true, options_or_listener) // optional user's native `FlurryMarketingOptions` or `FlurryMessagingListener`.
            .build(this, FLURRY_ANDROID_API_KEY);
    3. Add notification permission in the Android manifest file. (required on the Android 13 and above devices.)

       <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
    4. Set up "Android Authorization" in Flurry Push Authorization.

iOS

  • Please note that starting from React Native 0.60, CocoaPods is now the default integration approach for React Native iOS projects. If you are not using CocoaPods, please stick to [email protected].

  • Flurry Push
    To set up Flurry Push, please take the following steps.

    1. Open your Podfile, which is located under the ios folder of your project.

    2. Add the following line in your target section before use_native_modules!

      pod 'react-native-flurry-sdk', :path => '../node_modules/react-native-flurry-sdk/ios', :subspecs => ['FlurrySDK-Push']

      Your target section of Podfile should now look like this:

      target 'YourTarget' do
      
        # Pods for your target
        pod 'React', :path => '../node_modules/react-native/'
        pod 'React-Core', :path => '../node_modules/react-native/React'
        # ... other React dependencies
      
        # Add react-native-flurry-sdk
        pod 'react-native-flurry-sdk', :path => '../node_modules/react-native-flurry-sdk/ios', :subspecs => ['FlurrySDK-Push']
      
        # ... other targets
        target 'YourTargetTests' do
          # ...
        end
      
        use_native_modules!
      
      end
    3. Install the dependencies again by executing

      cd ios && pod install && cd ..
    4. Open your .xcworkspace file which is under the ios folder. Go to "Capabilities" tab and enable Push Notifications. push_ios_1

    5. Enable Background Modes (Background Fetch and Remote Notifications turned on). push_ios_2 Now your Info.plist should contain the following items. For more information, please see Push Setup. push_ios_3

    6. Set up "iOS Authorization" in Flurry Push Authorization.

    7. In order to handle notifications from a cold start, Flurry Push requires to be initialized from AppDelegate as early as possible. Please open AppDelegate.m, import the header file

      #import "ReactNativeFlurry.h"

      And add this line right after - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions

      [ReactNativeFlurry enableMessaging];

tvOS

  • Please note that Flurry Messaging and Flurry Config are currently not available on tvOS. For the detailed list of unavailable APIs, please see API reference below.

Example

  • index.js

    import { AppRegistry } from 'react-native';
    import { name as appName } from './app.json';
    import App from './App';
    import Flurry from 'react-native-flurry-sdk';
    
    // Init Flurry once as early as possible recommended in index.js.
    // For each platform (Android, iOS) where the app runs you need to acquire a unique Flurry API Key.
    // i.e., you need two API keys if you are going to release the app on both Android and iOS platforms.
    // If you are building for TV platforms, you will need two API keys for Android TV and tvOS.
    new Flurry.Builder()
      .withCrashReporting(true)
      .withLogEnabled(true)
      .withLogLevel(Flurry.LogLevel.DEBUG)
      .withReportLocation(true)
      .build(FLURRY_ANDROID_API_KEY, FLURRY_IOS_API_KEY);
    
    AppRegistry.registerComponent(appName, () => App);
  • App.js

    import React, { Component } from 'react';
    import {
      Platform,
      StyleSheet,
      Text,
      View
    } from 'react-native';
    import Flurry from 'react-native-flurry-sdk';
    
    type Props = {};
    export default class App extends Component<Props> {
      constructor(props) {
        super(props);
    
        // Example to get Flurry versions.
        Flurry.getVersions().then((versions) => {
          console.log('Versions: ' + versions.agentVersion + ' : ' + versions.releaseVersion + ' : ' + versions.sessionId);
        });
    
        // Example to get Flurry Publisher Segmentation.
        Flurry.getPublisherSegmentation(true).then((segmentations) => {
          console.log('Publisher Segmentation: ' + segmentations.segments);
        });
      }
    
      render() {
        // Set Flurry preferences.
        Flurry.setLogEnabled(true);
        Flurry.setLogLevel(Flurry.LogLevel.VERBOSE);
     
        // Set user preferences.
        Flurry.setAge(36);
        Flurry.setGender(Flurry.Gender.FEMALE);
        Flurry.setReportLocation(true);
    
        // Set user properties.
        Flurry.UserProperties.set(Flurry.UserProperties.PROPERTY_REGISTERED_USER, 'True');
    
        // Log Flurry events.
        Flurry.logEvent('React Native Event');
        Flurry.logEvent('React Native Timed Event', {param: 'true'}, true);
        ...
        Flurry.endTimedEvent('React Native Timed Event');
    
        // Log Flurry standard events.
        Flurry.logStandardEvent(Flurry.Event.APP_ACTIVATED);
        var params = new Map([
                         [Flurry.EventParam.TOTAL_AMOUNT, 34.99],
                         [Flurry.EventParam.SUCCESS, true],
                         [Flurry.EventParam.ITEM_NAME, 'book 1'],
                         ['note', 'This is an awesome book to purchase !!!']
                     ]);
        Flurry.logStandardEvent(Flurry.Event.PURCHASED, params);
    
        return (
          <View style={styles.container}>
            ...
          </View>
        );
      }
    }
    ...
  • index.js / Config.js

    Flurry.addConfigListener((event) => {
      if (event.Type === Flurry.ConfigStatus.SUCCESS) {
        // Data fetched, activate it.
        Flurry.activateConfig();
      } else if (event.Type === Flurry.ConfigStatus.ACTIVATED) {
        // Received cached data, or newly activated data.
        Flurry.getConfigString('welcome_message', 'Welcome!').then((value) => {
          console.log((event.isCache ? 'Received cached data: ' : 'Received newly activated data: ') + value.welcome_message);
        });
      } else if (event.Type === Flurry.ConfigStatus.UNCHANGED) {
        // Fetch finished, but data unchanged.
        Flurry.getConfigString('welcome_message', 'Welcome!').then((value) => {
          console.log('Received unchanged data: ' + value.welcome_message);
        });
      } else if (event.Type === Flurry.ConfigStatus.ERROR) {
        // Fetch failed.
        console.log('Fetch error! Retrying: ' + event.isRetrying);
      }
    });
    
    Flurry.fetchConfig();
  • index.js / Messaging.js

    // To customize Flurry Push for Android, please duplicate Builder setup in your MainApplication.java.
    new Flurry.Builder()
      .withMessaging(true)
      ...
    
    // Optionally add a listener to receive messaging events, and handle the notification.
    // Please call required Flurry.willHandleMessage(boolean) when received event types of
    // MessageType.RECEIVED or MessageType.CLICKED as soon as possible to avoid delay.
    Flurry.addMessagingListener((message) => {
      if (message.Type === Flurry.MessageType.RECEIVED) {
        Flurry.willHandleMessage(false);
      } else if (message.Type === Flurry.MessageType.CLICKED) {
        Flurry.willHandleMessage(false);
      }
    
      Flurry.printMessage(message);
    });

API Reference

See Android-(FlurryAgent) / iOS-(Flurry) for the Flurry references.

  • Methods to initialize Flurry

    Flurry.Builder.withAppVersion(versionName = '1.0'); // iOS only. For Android, please use Flurry.setVersionName() instead.
    Flurry.Builder.withContinueSessionMillis(sessionMillis = 10000);
    Flurry.Builder.withCrashReporting(crashReporting = true);
    Flurry.Builder.withGppConsent(gppString: string, gppSectionIds: number[]);
    Flurry.Builder.withDataSaleOptOut(isOptOut = false);
    Flurry.Builder.withIAPReportingEnabled(enableIAP = true); // iOS only.
    Flurry.Builder.withIncludeBackgroundSessionsInMetrics(includeBackgroundSessionsInMetrics = true);
    Flurry.Builder.withLogEnabled(enableLog = true);
    Flurry.Builder.withLogLevel(logLevel = Flurry.LogLevel.WARN); // LogLevel = { VERBOSE, DEBUG, INFO, WARN, ERROR, ASSERT }
    Flurry.Builder.withReportLocation(reportLocation = true); // Android only
    Flurry.Builder.withPerformanceMetrics(performanceMetrics = Flurry.Performance.ALL); // Performance = { NONE, COLD_START, SCREEN_TIME, ALL }
    Flurry.Builder.withSslPinningEnabled(sslPinningEnabled = false); // Android only
    Flurry.Builder.withMessaging(enableMessaging = true); // not available on tvOS
    
    Flurry.Builder.build(apiKeyAndroid: string, apiKeyIos: string);  // preferred; passing null if not available
    Flurry.Builder.build(apiKey: string);  // use when only single platform is supported, or shared (not recommended)
    
    // tvOS only
    Flurry.Builder.withTVSessionReportingInterval(interval = 5);
    Flurry.Builder.withTVEventCountThreshold(threshold = 10);
  • Methods to set Flurry preferences

    Flurry.setContinueSessionMillis(sessionMillis = 10000);
    Flurry.setCrashReporting(crashReporting = true);
    Flurry.setIncludeBackgroundSessionsInMetrics(includeBackgroundSessionsInMetrics = true);
    Flurry.setLogEnabled(enableLog = true);
    Flurry.setLogLevel(logLevel = Flurry.LogLevel.WARN); // LogLevel = { VERBOSE, DEBUG, INFO, WARN, ERROR, ASSERT }
    Flurry.setSslPinningEnabled(sslPinningEnabled = false); // Android only
  • Methods to set user preferences

    Flurry.setAge(age: number);
    Flurry.setGender(gender: Flurry.Gender); // Gender = { MALE, FEMALE }
    Flurry.setReportLocation(reportLocation: boolean);
    Flurry.setSessionOrigin(originName: string, deepLink: string);
    Flurry.setUserId(userId: string);
    Flurry.setVersionName(versionName: string); // Android only. For iOS, please use Flurry.Builder.withAppVersion() instead.
    
    Flurry.addOrigin(originName: string, originVersion: string);
    Flurry.addOrigin(originName: string, originVersion: string, originParameters: { [key: string]: string; });
    Flurry.addSessionProperty(name: string, value: string);
  • Methods to set privacy preferences

    Flurry.setGppConsent(gppString: string, gppSectionIds: number[]);
    Flurry.setDataSaleOptOut(isOptOut: boolean);
    Flurry.deleteData();
    Flurry.openPrivacyDashboard();
  • Methods to set user properties

    // Standard User Properties: Flurry.UserProperties = {
    //     PROPERTY_CURRENCY_PREFERENCE, PROPERTY_PURCHASER, PROPERTY_REGISTERED_USER, PROPERTY_SUBSCRIBER }
    Flurry.UserProperties.set(propertyName: string, propertyValue:  string);
    Flurry.UserProperties.set(propertyName: string, propertyValues: string[]);
    Flurry.UserProperties.add(propertyName: string, propertyValue:  string);
    Flurry.UserProperties.add(propertyName: string, propertyValues: string[]);
    Flurry.UserProperties.remove(propertyName: string);
    Flurry.UserProperties.remove(propertyName: string, propertyValue:  string);
    Flurry.UserProperties.remove(propertyName: string, propertyValues: string[]);
    Flurry.UserProperties.flag(propertyName: string);
  • Methods to get Flurry versions and publisher segmentation

    Flurry.getVersions(): Promise<{ agentVersion: number; releaseVersion: string; sessionId: string; }>;
    Flurry.getVersions(errorCallback: (errorMessage: string) => void,
                       successCallback: (agentVersion: number, releaseVersion: string, sessionId: string) => void);
    
    Flurry.getPublisherSegmentation(refresh?: boolean): Promise<{ segments: string }>;
    Flurry.fetchPublisherSegmentation();
  • Methods to log Flurry events

    Flurry.logEvent(eventId: string);
    Flurry.logEvent(eventId: string, parameters: { [key: string]: string; });
    Flurry.logEvent(eventId: string, timed: boolean);
    Flurry.logEvent(eventId: string, parameters: { [key: string]: string; }, timed: boolean);
    Flurry.logEvent(eventId: string, timedId: string);
    Flurry.logEvent(eventId: string, parameters: { [key: string]: string; }, timedId: string);
    
    Flurry.endTimedEvent(eventId: string);
    Flurry.endTimedEvent(eventId: string, parameters: { [key: string]: string; });
    Flurry.endTimedEvent(eventId: string, timedId: string);
    Flurry.endTimedEvent(eventId: string, parameters: { [key: string]: string; }, timedId: string);
    
    Flurry.logStandardEvent(eventId: Flurry.Event);
    Flurry.logStandardEvent(eventId: Flurry.Event, parameters: { [key: Flurry.EventParam]: object; });
    
    Flurry.onPageView(); // Deprecated, API removed, no longer supported by Flurry.
    
    Flurry.onError(errorId: string, message: string, errorClass: string);
    Flurry.onError(errorId: string, message: string, errorClass: string, errorParams: { [key: string]: string; });
    
    Flurry.logBreadcrumb(crashBreadcrumb: string);
    Flurry.logPayment(productName: string, productId: string, quantity: number, price: number,
                      currency: string, transactionId: string, parameters: { [key: string]: string; });
  • Methods to enable IAP reporting (iOS and tvOS)

    Flurry.setIAPReportingEnabled(enableIAP: boolean);
  • Methods to set the iOS conversion value sent to Apple through SKAdNetwork (iOS)

    Flurry.updateConversionValue(conversionValue: number)
    Flurry.updateConversionValueWithEvent(flurryEvent: Flurry.SKAdNetworkEvent); // SKAdNetworkEvent = { NO_EVENT, REGISTRATION, LOGIN, SUBSCRIPTION, IN_APP_PURCHASE }
  • Methods for Flurry Performance Metrics

    Flurry.Performance.startResourceLogger();
    Flurry.Performance.logResourceLogger(id: string);
    Flurry.Performance.reportFullyDrawn();
  • Methods for Flurry Config

    // Event.Type:       Flurry.ConfigStatus = { SUCCESS, UNCHANGED, ERROR, ACTIVATED }
    // Event.isRetrying: true if it is still retrying fetching, for ERROR type
    // Event.isCache:    true if activated from the cached data, for ACTIVATED type
    Flurry.addConfigListener   (callback: (event: { Type: string; isCache?: boolean; isRetrying?: boolean; }) => void);
    Flurry.removeConfigListener(callback: (event: { Type: string; isCache?: boolean; isRetrying?: boolean; }) => void);
    Flurry.fetchConfig();
    Flurry.activateConfig():
    Flurry.getConfigString(key: string, defaultValue: string):           Promise<{ [key: string]: string; }>;
    Flurry.getConfigString(keysAndDefaults: { [key: string]: string; }): Promise<{ [key: string]: string; }>;
  • Methods for Messaging (Flurry Push)

    // Message.Type: Flurry.MessageType = { RECEIVED,  CLICKED,
    //                                      CANCELLED, REFRESH } (Android only)
    // Message.Title:       message title
    // Message.Body:        message body
    // Message.Data:        message data (Map)
    // Message.ClickAction: click action (Android only)
    // Message.Token:       refreshed token
    Flurry.addMessagingListener(callback: (message: { Type: string;
                      Title?: string; Body?: string; Data?: { [key: string]: string; }; ClickAction?: string;
                      Token?: string; }) => void);
    Flurry.removeMessagingListener(callback: (message: { Type: string;
                      Title?: string; Body?: string; Data?: { [key: string]: string; }; ClickAction?: string;
                      Token?: string; }) => void);
    Flurry.willHandleMessage(handled: boolean);
    Flurry.printMessage(message: { Type: string;
                      Title?: string; Body?: string; Data?: { [key: string]: string; }; ClickAction?: string;
                      Token?: string; });

Support

License

Copyright 2022 Yahoo Inc.

This project is licensed under the terms of the Apache 2.0 open source license. Please refer to LICENSE for the full terms.

react-native-flurry-sdk's People

Contributors

poting-oath avatar xnth97 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-native-flurry-sdk's Issues

Upgrade from 5.5.0 to 6.0.0 causes "[!] [Xcodeproj] Generated duplicate UUIDs" error

Upgrade from 5.5.0 to 6.0.0 causes [!] [Xcodeproj] Generated duplicate UUIDs on running pod install.
react-native 0.62.2

This Bug is About

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform

  • Android
  • iOS
  • tvOS

Additional context
Are you using Flurry Push/Messaging? Yes / No
(iOS) Are you using CocoaPods for React Native integration? Yes / No

Here is a part of the output:

[!] [Xcodeproj] Generated duplicate UUIDs:

PBXFileReference --Pods.xcodeproj/mainGroup/children/children:children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:Analytics,isa:PBXGroup,name:Analytics,path:Analytics,sourceTree:,,children:|,|,|,|,|,displayName:CocoaAsyncSocket,isa:PBXGroup,name:CocoaAsyncSocket,path:CocoaAsyncSocket,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:CocoaLibEvent,isa:PBXGroup,name:CocoaLibEvent,path:CocoaLibEvent,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:DoubleConversion,isa:PBXGroup,name:DoubleConversion,path:DoubleConversion,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:Flipper,isa:PBXGroup,name:Flipper,path:Flipper,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:Flipper-DoubleConversion,isa:PBXGroup,name:Flipper-DoubleConversion,path:Flipper-DoubleConversion,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:Flipper-Folly,isa:PBXGroup,name:Flipper-Folly,path:Flipper-Folly,sourceTree:,,children:|,|,|,|,|,|,|,|,|,|,|,|,|,displayName:Flipper-Glog,isa:PBXGroup,name:Flipper-Glog,path:Flipper-Glog,sourceTree:,,children:|,|,|,|,|,|,|,|,|,displayName:Flipper-PeerTalk,isa:PBXGroup,name:Flipper-PeerTalk,path:Flipper-PeerTalk,sourceTree:,,children:|,|,|,|,|,|,|,|,|...

SDK crash on iOS - FlurrySignalConnectionTypeDataProvider

Describe the bug
I have a lot of crashes in Crashlytics in iOS.

FlurrySignalConnectionTypeDataProvider.m line 89
-[FlurrySignalConnectionTypeDataProvider onqueue_getCellularSignalConnectionType]

Devices:

iPhone 8 Plus -  13.5.1 (17F80)
iPhone SE (2nd generation) -  13.5.1 (17F80)
iPhone 8 - 13.5.1 (17F80)

Stack trace:

FlurrySignalConnectionTypeDataProvider.m line 89
-[FlurrySignalConnectionTypeDataProvider onqueue_getCellularSignalConnectionType]

Crashed: FlurrySignalConnectionTypeDataProvider
0  libobjc.A.dylib                0x19c3b6980 objc_retain + 16
1  CoreFoundation                 0x19c5def7c __NSSingleObjectArrayI_new + 84
2  CoreFoundation                 0x19c556454 -[NSDictionary allValues] + 312
3  xxx                            0x1042ddf34 -[FlurrySignalConnectionTypeDataProvider onqueue_getCellularSignalConnectionType] + 89 (FlurrySignalConnectionTypeDataProvider.m:89)
4  xxx                            0x1042de494 -[FlurrySignalConnectionTypeDataProvider onqueue_connectionTypeChanged] + 157 (FlurrySignalConnectionTypeDataProvider.m:157)
5  xxx                            0x10429ffc0 __30-[FlurryActor wrapAsyncBlock:]_block_invoke + 321 (FlurryActor.m:321)
6  libdispatch.dylib              0x19c33e9a8 _dispatch_call_block_and_release + 24
7  libdispatch.dylib              0x19c33f524 _dispatch_client_callout + 16
8  libdispatch.dylib              0x19c31cb3c _dispatch_lane_serial_drain$VARIANT$armv81 + 564
9  libdispatch.dylib              0x19c31d54c _dispatch_lane_invoke$VARIANT$armv81 + 396
10 libdispatch.dylib              0x19c32684c _dispatch_workloop_worker_thread + 580
11 libsystem_pthread.dylib        0x19c390b74 _pthread_wqthread + 272
12 libsystem_pthread.dylib        0x19c393740 start_wqthread + 8

This Bug is About

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform

  • Android
  • iOS
  • tvOS

Environment

  • React Native version: 0.61.5
  • react-native-flurry-sdk version: 5.6.0

To Reproduce
I can't reproduce in my environment, I have this crash in Crashlytics.

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

null is not an object (evaluating 'ReactNativeFlurry.initBuilder') while using Expo

Describe the bug
Basically running into this bug when trying to init Flurry in my Expo project. Being that Expo's entry point is essentially App.js I call this method towards the bottom of my file before exporting. Can this package be used with Expo? I've been searching all over and haven't found instructions to use it in unison with it.

This Bug is About

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Environment

  • React Native version: 0.63.2
  • react-native-flurry-sdk version: 6.2.0

To Reproduce

  1. Happens on build: expo start

App.js

// ...

import Flurry from 'react-native-flurry-sdk';

// ...

new Flurry.Builder()
  .withCrashReporting(true)
  .withLogEnabled(true)
  .withLogLevel(Flurry.LogLevel.DEBUG)
  .build('ANDROID_API_KEY', 'IOS_API_KEY');

export default () => (
  <Provider store={ store }>
     <PersistGate
       loading={ null }
       persistor={ persistor }
      >
      <AppContainer/>
    </PersistGate>
  </Provider>
);

Screenshots
image

Retrieve Device Token

Is there a way to retrieve the device push notification token?

Below Method "onTokenRefresh" gets fired before I can add a messaging listener, so the event is never triggered as sEnableMessagingListener false at that time.

@Override
        public void onTokenRefresh(String token) {
            if (sEnableMessagingListener && (sReactApplicationContext != null)) {
                sendEvent(EventType.TokenRefresh, token);
            }
        }

NullPointerException: Attempt to invoke virtual method 'FlurryMessage.getNotificationId()' on a null object reference

Describe the bug
I have this crash on Crashlytics (Android), I don't know how to reproduce it.

Caused by java.lang.NullPointerException
Attempt to invoke virtual method 'int com.flurry.android.marketing.messaging.notification.FlurryMessage.getNotificationId()' on a null object reference

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.63.3
  • react-native-flurry-sdk version: 6.1.0

To Reproduce
I have this crash on Crashlytics (Android), I don't know how to reproduce it. Sorry.

Screenshots
From Crashlytics

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Stacktrace

Fatal Exception: java.lang.RuntimeException: Unable to start receiver com.flurry.android.marketing.messaging.notification.NotificationCancelledReceiver: java.lang.NullPointerException: Attempt to invoke virtual method 'int com.flurry.android.marketing.messaging.notification.FlurryMessage.getNotificationId()' on a null object reference
       at android.app.ActivityThread.handleReceiver(ActivityThread.java:2735)
       at android.app.ActivityThread.-wrap14(ActivityThread.java)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1424)
       at android.os.Handler.dispatchMessage(Handler.java:102)
       at android.os.Looper.loop(Looper.java:148)
       at android.app.ActivityThread.main(ActivityThread.java:5421)
       at java.lang.reflect.Method.invoke(Method.java)
       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.NullPointerException: Attempt to invoke virtual method 'int com.flurry.android.marketing.messaging.notification.FlurryMessage.getNotificationId()' on a null object reference
       at com.flurry.android.marketing.messaging.notification.NotificationCancelledReceiver.onReceive(SourceFile:24)
       at android.app.ActivityThread.handleReceiver(ActivityThread.java:2728)
       at android.app.ActivityThread.-wrap14(ActivityThread.java)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1424)
       at android.os.Handler.dispatchMessage(Handler.java:102)
       at android.os.Looper.loop(Looper.java:148)
       at android.app.ActivityThread.main(ActivityThread.java:5421)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Device

  • Brand: LGE
  • Model: Nexus 4
  • Android Version: 6.0.1

TypeError: null is not an object (evaluating 'ReactNativeFlurry.initBuilder')

Describe the bug
In index.js where we init the builder results in a crash.
Error message: TypeError: null is not an object (evaluating 'ReactNativeFlurry.initBuilder')
which then crashes the app with
When we uncomment the flurry builder, it works.
We have used flurry for a long time with no issues.

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • [x ] Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • [ x] iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: "0.69.5",
  • react-native-flurry-sdk version: "7.3.0",

To Reproduce
Steps to reproduce the behavior:

  1. create react native project
  2. in the index js, init the builder
    new Flurry.Builder()
    .withCrashReporting(true)
    .withLogEnabled(true)
    .withLogLevel(Flurry.LogLevel.DEBUG)
    .build(FLURRY_ANDROID_API_KEY, FLURRY_IOS_API_KEY);

Error message: TypeError: null is not an object (evaluating 'ReactNativeFlurry.initBuilder')
app crashes with invariant view error.
"""
Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.
This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.
"""

When we uncomment the flurry builder, everything works well.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Add any other context about the problem here.

null is not an object (evaluating RNFlurryAnalytics)

Describe the bug
Flurry does not appear to be working correctly.

pod install

results in the following error:

[!] No podspec found for `react-native-flurry-sdk` in `../node_modules/react-native-flurry-sdk/ios`

[!] use_native_modules! skipped the react-native dependency 'react-native-flurry-analytics'. No podspec file was found.
    - Check to see if there is an updated version that contains the necessary
    podspec file
    - Contact the library maintainers or send them a PR to add a podspec. The
    react-native-webview podspec is a good example of a package.json driven
    podspec. See
    https://github.com/react-native-community/react-native-webview/blob/master/react-native-webview.podspec
    - If necessary, you can disable autolinking for the dependency and link it
    manually. See
    https://github.com/react-native-community/cli/blob/master/docs/autolinking.md#how-can-i-disable-autolinking-for-unsupported-library

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
react-native-cli: 2.0.1
react-native: 0.63.4

"react-native-flurry-analytics": "^3.0.3",

To Reproduce

Screenshots
Simulator Screen Shot - iPhone 11 - 2021-01-11 at 13 30 53

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Add any other context about the problem here.

Apple tvOS support

Hi, we're trying to add this library to an Apple TV app however we're getting the error:

undefined is not an object (evaluating 'ReactNativeFlurry.initBuilder')

It's working on iOS and Android TV but not having any luck with tvOS. I can see that the native Flurry SDK supports tvOS, does this react native module provide support as well?

Thanks

Flurry not capturing userId and Location data upto city/state level

Describe the bug
A clear and concise description of what the bug is.

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.62.2
  • react-native-flurry-sdk version: 6.1.9

To Reproduce
Steps to reproduce the behavior:

  1. Normal Flurry React Native setup.
  2. setting Flurry.setReportLocation(true);
  3. setting Flurry.setUserId(someCustomGeneratedId);

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Are you using Flurry Push/Messaging? Yes / No No
(iOS) Are you using CocoaPods for React Native integration? Yes / No Yes

Add any other context about the problem here.
I have added all location permissions on Android and have successfully requested and started location watching prior to setting Flurry.setReportLocation(true). I am also not able to see the userIds in the dashboard.

Xcode failing to build for simulator

Describe the bug
Xcode build fails when trying on Simulator

This Bug is About

  • Integration

Platform

  • iOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.63.2
  • react-native-flurry-sdk version: 6.1.0

To Reproduce
Steps to reproduce the behavior:

  1. From XCode Select a Simulator and build

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Are you using Flurry Push/Messaging?
No

(iOS) Are you using CocoaPods for React Native integration?
Yes

ld: in /ios/Pods/Flurry-iOS-SDK/FlurryConfig/libFlurryConfig_11.1.0.a(libFlurryConfig.a-arm64-master.o), building for iOS Simulator, but linking in object file built for iOS, file '/ios/Pods/Flurry-iOS-SDK/FlurryConfig/libFlurryConfig_11.1.0.a'
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Push Notification Campaign doesn't work on Android

Describe the bug
The push notifications campaign doesn't work on Android, even if the test notification works when we send it with push token before starting the campaign.
On iOS everything works fine.

This Bug is About

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform

  • Android
  • iOS
  • tvOS

Environment

  • React Native version: "react-native": "0.63.4",
  • react-native-flurry-sdk version: "6.4.0"

To Reproduce
Steps to reproduce the behavior:

  1. Add flurry manual/automate configuration
  2. Create a campaign
  3. Test the notification with Android push token (here it works)
  4. Start the campaign (the messages are never sent/received)

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Are you using Flurry Push/Messaging? Yes

Add any other context about the problem here.

This is the MainApplication.java


package com.myspecificapp.app

import android.app.Application;
import android.app.Notification;
import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.content.Context;
import android.net.Uri;
import android.os.AsyncTask;
import android.os.Build;
import android.util.Log;
import android.widget.Toast;

import com.facebook.react.PackageList;
import com.facebook.react.ReactApplication;
import com.facebook.react.ReactInstanceManager;
import com.flurry.android.reactnative.FlurryModule;
import com.flurry.android.reactnative.FlurryPackage;
import com.flurry.android.FlurryAgent;
import com.flurry.android.marketing.FlurryMarketingModule;
import com.flurry.android.marketing.messaging.FlurryMessaging;
import com.flurry.android.marketing.messaging.FlurryMessagingListener;
import com.flurry.android.marketing.messaging.notification.FlurryMessage;
import com.flurry.android.reactnative.FlurryPackage;
import com.flurry.android.reactnative.FlurryPackage;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;
import com.facebook.soloader.SoLoader;
import com.myspecificapp.app.generated.BasePackageList;
import org.unimodules.adapters.react.ReactAdapterPackage;

import org.unimodules.adapters.react.ModuleRegistryAdapter;
import org.unimodules.adapters.react.ReactModuleRegistryProvider;
import org.unimodules.core.interfaces.Package;
import org.unimodules.core.interfaces.SingletonModule;

import expo.modules.constants.ConstantsPackage;
import expo.modules.permissions.PermissionsPackage;
import expo.modules.filesystem.FileSystemPackage;
import expo.modules.updates.UpdatesController;

import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.util.Arrays;
import java.util.List;

import javax.annotation.Nullable;
import com.facebook.react.bridge.JSIModulePackage;
import com.google.android.gms.ads.identifier.AdvertisingIdClient;
import com.google.android.gms.common.GooglePlayServicesNotAvailableException;
import com.google.android.gms.common.GooglePlayServicesRepairableException;
import com.google.android.gms.tasks.Task;
import com.google.firebase.iid.internal.FirebaseInstanceIdInternal;
import com.google.firebase.messaging.FirebaseMessaging;
import com.google.firebase.messaging.RemoteMessage;
import com.swmansion.reanimated.ReanimatedJSIModulePackage;

import com.flurry.android.marketing.FlurryMarketingOptions;
import com.dieam.reactnativepushnotification.ReactNativePushNotificationPackage;




import androidx.multidex.MultiDexApplication;


public class MainApplication extends MultiDexApplication implements ReactApplication {
    private final ReactModuleRegistryProvider mModuleRegistryProvider = new ReactModuleRegistryProvider(
            new BasePackageList().getPackageList()
    );




    private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
        

        @Override
        protected String getJSMainModuleName() {
            return "index";
        }

        @Override
        protected JSIModulePackage getJSIModulePackage() {
            return new ReanimatedJSIModulePackage(); 
        }

        @Override
        public boolean getUseDeveloperSupport() {
            return BuildConfig.DEBUG;
        }

        @Override
        protected List<ReactPackage> getPackages() {
            List<ReactPackage> packages = new PackageList(this).getPackages();
            new ReactNativePushNotificationPackage(); 
            packages.add(new ModuleRegistryAdapter(mModuleRegistryProvider));
            return packages;
        }


        @Override
        protected @Nullable
        String getJSBundleFile() {
            if (BuildConfig.DEBUG) {
                return super.getJSBundleFile();
            } else {
                return UpdatesController.getInstance().getLaunchAssetFile();
            }
        }

        @Override
        protected @Nullable
        String getBundleAssetName() {
            if (BuildConfig.DEBUG) {
                return super.getBundleAssetName();
            } else {
                return UpdatesController.getInstance().getBundleAssetName();
            }
        }
    };

    @Override
    public ReactNativeHost getReactNativeHost() {
        return mReactNativeHost;
    }


    @Override
    public void onCreate() {
        super.onCreate();

        String refreshedToken =  MyFirebaseMessagingService.getToken(this);

        FlurryMessagingListener myFlurryMessagingListener = new MyFlurryMessagingListener(this);

        FlurryMarketingOptions flurryMessagingOptions = new FlurryMarketingOptions.Builder()
                .setupMessagingWithAutoIntegration()
                .withDefaultNotificationChannelId(String.valueOf(R.string.default_notification_channel_id))
                .withDefaultNotificationIconResourceId(R.drawable.ic_stat_ic_notification)
                .withDefaultNotificationIconAccentColor(getResources().getColor(R.color.splashscreen_bg))
                .withFlurryMessagingListener(myFlurryMessagingListener)
                .build();

        FlurryMarketingModule marketingModule = new FlurryMarketingModule(flurryMessagingOptions);

        new FlurryAgent.Builder()
                .withModule(marketingModule)
                .withIncludeBackgroundSessionsInMetrics(true)
                .build(this, "Our specific token");

        FlurryMessaging.setToken(refreshedToken);
        Log.d("Message is: ", "Set token done with: " + refreshedToken);

        FlurryMessaging.setToken(refreshedToken);



        SoLoader.init(this, /* native exopackage */ false);
        initializeFlipper(this); // Remove this line if you don't want Flipper enabled
        if (!BuildConfig.DEBUG) {
            UpdatesController.initialize(this);
        }

    }

    /**
     * Loads Flipper in React Native templates.
     *
     * @param context
     */
    private static void initializeFlipper(Context context) {
        if (BuildConfig.DEBUG) {
            try {
         /*
          We use reflection here to pick up the class that initializes Flipper,
         since Flipper library is not available in release mode
         */
                Class<?> aClass = Class.forName("com.facebook.flipper.ReactNativeFlipper");
                aClass.getMethod("initializeFlipper", Context.class).invoke(null, context);
            } catch (ClassNotFoundException e) {
                e.printStackTrace();
            } catch (NoSuchMethodException e) {
                e.printStackTrace();
            } catch (IllegalAccessException e) {
                e.printStackTrace();
            } catch (InvocationTargetException e) {
                e.printStackTrace();
            }
        }
    }
}

Logging events doesn't work

i'm integrating flurry with my react-native app. I use [email protected] with [email protected]. I did everything acัording with https://www.npmjs.com/package/react-native-flurry-sdk, but i couldn't send events. Most of them(events) doesn't received by platform. Only a few part of them reach the target with a big delay(a couple of hours).

This is my flurry settings:

import Flurry from "react-native-flurry-sdk";

const FLURRY_ANDROID_API_KEY = "...";
const FLURRY_IOS_API_KEY = "...";

new Flurry.Builder()
  .withCrashReporting(true)
  .withLogEnabled(true)
  .withLogLevel(Flurry.LogLevel.DEBUG)
  .build(FLURRY_ANDROID_API_KEY, FLURRY_IOS_API_KEY);

Flurry.logEvent("1", { param: "true" }, true);
Flurry.endTimedEvent("React Native Timed Event");

What is wrong?

5.4.0 pod install error

Since your last update 5.4.0 I have this error when I run pod install :

[!] CocoaPods could not find compatible versions for pod "Flurry-iOS-SDK/FlurryConfig":
  In Podfile:
    react-native-flurry-sdk (from `../node_modules/react-native-flurry-sdk/ios`) was resolved to 5.4.0, which depends on
      react-native-flurry-sdk/FlurrySDK (= 5.4.0) was resolved to 5.4.0, which depends on
        Flurry-iOS-SDK/FlurryConfig (~> 10.3.0)

Crashes on iOS in production

Since the 18th september 2020, we notice a lot of crashes on Crashlytics comingย from Flurry SDK in most of our appsย that use react-native-flurry-sdk 4.1.0 or lower versions. Most of theseย apps have notย been updated in the last 6 months. We have a lot of apps and could not afford an update for each of them.

Here is the meaningful part of the stack trace :ย 

Fatal Exception: NSInvalidArgumentException
-[__NSDictionaryM setObject:forKey:]: object cannot be nil (key: fl.TransactionIdentifier)
0 ย CoreFoundation ย  ย  ย  ย  ย  ย  ย  ย  0x19cf1a5ac __exceptionPreprocess
1 ย libobjc.A.dylib ย  ย  ย  ย  ย  ย  ย  ย 0x1b0f9442c objc_exception_throw
2 ย CoreFoundation ย  ย  ย  ย  ย  ย  ย  ย  0x19cf894cc -[__NSCFString characterAtIndex:].cold.1
3 ย CoreFoundation ย  ย  ย  ย  ย  ย  ย  ย  0x19cf9580c -[__NSDictionaryM setObject:forKey:].cold.3
4 ย CoreFoundation ย  ย  ย  ย  ย  ย  ย  ย  0x19cdfed44 -[__NSDictionaryM setObject:forKey:]
5 ย APP_NAME ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  0x10468bc40 -[FlurryRecordTransactionRequestManager eventParamsWithTransaction:]
6 ย APP_NAME ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  0x10468b61c __76-[FlurryRecordTransactionRequestManager doRecordTransaction:statusCallback:]_block_invoke_3

This Bug is About

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform

  • Android
  • iOS
  • tvOS

Environment

  • React Native version: 0.60.5
  • react-native-flurry-sdk version: 4.1.0

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Thank you

Cannot read property 'initBuilder' of undefined

Hi, I'm getting this error when calling Builder method
Cannot read property 'initBuilder' of undefined

here is my dependencies:
"dependencies": {
"@react-native-community/async-storage": "^1.3.3",
"lottie-react-native": "^2.6.1",
"react": "16.8.4",
"react-native": "^0.59.6",
"react-native-background-timer": "^2.1.1",
"react-native-base64": "0.0.2",
"react-native-firebase": "~5.5.5",
"react-native-flurry-sdk": "^3.7.0",
"react-native-gesture-handler": "^1.0.16",
"react-native-keep-awake": "^4.0.0",
"react-native-sound": "^0.10.12",
"react-native-svg": "^9.2.4",
"react-native-walkthrough-tooltip": "^0.6.1",
"react-native-webview": "^5.12.1",
"react-navigation": "^3.3.2",
"react-redux": "^7.0.2",
"realm": "^2.29.0",
"redux": "^4.0.1"
},

Should support external SDK version on Android

This Feature Request is About
Should support external SDK version on Android

Platform

  • Android
apply plugin: 'com.android.library'

buildscript {
    repositories {
        google()
        jcenter()
    }

    dependencies {
        classpath "com.android.tools.build:gradle:3.2.1"
    }
}

def safeExtGet(prop, fallback) {
    rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
}

android {
    compileSdkVersion safeExtGet('compileSdkVersion', 28)
    buildToolsVersion safeExtGet('buildToolsVersion', '28.0.3')

    defaultConfig {
        minSdkVersion safeExtGet('minSdkVersion', 16)
        targetSdkVersion safeExtGet('targetSdkVersion', 28)
        versionCode 1
        versionName "1.0"
    }
    lintOptions {
        abortOnError false
    }
}

repositories {
    mavenLocal()
    maven {
        // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
        url "$projectDir/../../../node_modules/react-native/android"
    }
    mavenCentral()
    google()
    jcenter()
}

dependencies {
    // implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])

    implementation 'com.facebook.react:react-native:+'
    implementation 'com.flurry.android:analytics:13.1.0'
    implementation 'com.flurry.android:marketing:13.1.0'
}


About the best practices to initialize flurry sdk

Current Behavior (using js)

case 1: crash

By using getCurrentActivity method to initialize Flurry Sdk, app may crash in some rare situations. I can't reproduce in development.

The getCurrentActivity sometimes returns null. Some stacktrace like below:

Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.res.Resources android.content.Context.getResources()' on a null object reference
at com.flurry.android.FlurryAgent.a(SourceFile:5297)
at com.flurry.android.FlurryAgent$Builder.build(SourceFile:1529)
at com.flurry.android.reactnative.FlurryModule.init(FlurryModule.java:66)
at java.lang.reflect.Method.invoke(Method.java)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:160)
at com.facebook.react.bridge.queue.NativeRunnable.run(NativeRunnable.java)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29)
at android.os.Looper.loop(Looper.java:154)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:192)
at java.lang.Thread.run(Thread.java:7611)

FYI: #facebook/react-native#18345

case 2: flurry session

Using getReactApplicationContext as context to initialiaze SDK will prevent app crash, but

will cause "D FlurryAgent: There is no active Flurry session. Adding this event to deferred queue and flush them when the session initializes. Event: Some Event".

See: #3

Best Practices (native codes)

Prefer to use only native codes ( like java / Objective-C ) rather than js to initialize Flurry SDK. See Doc#Initialize Flurry

Sessions not reporting in dashboard

Hi! Maybe this does not belong in here, but I'll give it a try.

I did the setup without any problem, but now I see the following issues:

  • Events are shown in dashboard with several hours of delay.
  • No session is being shown in the dashboard. This is what matters the most

Is there any additional step needed to start reporting sessions?

This is my code

new Flurry.Builder()
      .withCrashReporting(true)
      .withLogEnabled(true)
      .withLogLevel(Flurry.LogLevel.DEBUG)
      .build(Config.FLURRY_ANDROID_API_KEY, Config.FLURRY_IOS_API_KEY);

and then

Flurry.logEvent('React Native Event');

Missing package attribute in AndroidManifest causes android build fails

Describe the bug
Hi, thanks for this library.
In the last commit (v.8.3.0) the package attribute has been removed from AndroidManifest.xml.
It causes gradle build fails with this error:

error: package undefined does not exist import undefined.FlurryPackage;

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.68.7
  • react-native-flurry-sdk version: 8.3.0

To Reproduce
Steps to reproduce the behavior:

  1. yarn add [email protected]
  2. Build android
  3. Build fails

Pod Spec file not found

Describe the bug
When following the additional instructions for iOS integration to enable Push Notifications. When I got to the pod instructions I attempted to add the following:
pod 'react-native-flurry-sdk', :path => '../node_modules/react-native-flurry-sdk/ios', :subspecs => ['FlurrySDK-Push']

I then ran the following commands:
cd ios && pod install && cd ..

I then received the following error for cocoapods:

[!] No podspec found for `react-native-flurry-sdk` in `../node_modules/react-native-flurry-sdk/ios

After I looked at the react-native-flurry-sdk directory under node_modules I saw that the spec file was at ../node_modules/react-native-flurry-sdk and not ../node_modules/react-native-flurry-sdk/ios so I changed the pod line in the podfile to point to the base node_module and ran the pod install and the install finished. But when I went to run the react native ios build, it failed due to not being able to find the ReactNativeFlurry.h file. Is there something I'm doing wrong?

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • [x ] Analytics
  • [ x] Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.71.8
  • react-native-flurry-sdk version: 8.3.0

To Reproduce
Steps to reproduce the behavior:
I simply followed the instructions given in this repo.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Are you using Flurry Push/Messaging? Yes
(iOS) Are you using CocoaPods for React Native integration? Yes

Add any other context about the problem here.

ITMS-90078: Missing Push Notification Entitlement - Your app appears to register with the Apple Push Notification service, but the app signature's entitlements do not include the "aps-environment" entitlement.

I just added this SDK to my existing RN project and put up a TestFlight build. I then received an email from Apple saying:

ITMS-90078: Missing Push Notification Entitlement - Your app appears to register with the Apple Push Notification service, but the app signature's entitlements do not include the "aps-environment" entitlement.

However, I don't want to use push notifications at the moment. Is there some way to avoid this?

Fatal Exception: NSInvalidArgumentException unrecognized selector sent to instance

Describe the bug
I have this bug in Crashlytics, I don't know how to reproduce it.

FlurryDataSender.m line 323
-[FlurryDataSender retransmitNotSentBlocks]

Fatal Exception: NSInvalidArgumentException
-[__NSArrayM tag]: unrecognized selector sent to instance 0x282a87d20

Fatal Exception: NSInvalidArgumentException
0  CoreFoundation                 0x92d0c __exceptionPreprocess
1  libobjc.A.dylib                0x14ee4 objc_exception_throw
2  CoreFoundation                 0x163750 +[NSObject(NSObject) _copyDescription]
3  CoreFoundation                 0x2c60c ___forwarding___
4  CoreFoundation                 0x2b81c _CF_forwarding_prep_0
5  X                              0x23e5d4 -[FlurryDataSender retransmitNotSentBlocks] + 323 (FlurryDataSender.m:323)
6  X                              0x24c724 -[FlurryDataSenderBase unregisterTask:completedSuccessfuly:] + 100 (FlurryDataSenderBase.m:100)
7  X                              0x23e3f4 -[FlurryDataSender requestSuccessComplete:withResponse:] + 305 (FlurryDataSender.m:305)
8  X                              0x23e0c4 __60-[FlurryDataSender flurryUrlRequestDidSucceed:withResponse:]_block_invoke + 271 (FlurryDataSender.m:271)
9  libdispatch.dylib              0x63094 _dispatch_call_block_and_release
10 libdispatch.dylib              0x64094 _dispatch_client_callout
11 libdispatch.dylib              0xa73c _dispatch_lane_serial_drain$VARIANT$mp
12 libdispatch.dylib              0xb1f4 _dispatch_lane_invoke$VARIANT$mp
13 libdispatch.dylib              0x14ec8 _dispatch_workloop_worker_thread
14 libsystem_pthread.dylib        0x1e10 _pthread_wqthread
15 libsystem_pthread.dylib        0x193c start_wqthread

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.68.2
  • react-native-flurry-sdk version: 7.2.0

To Reproduce
I have this bug in Crashlytics, I don't know how to reproduce it.

Screenshots

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Add any other context about the problem here.

Retrieve FCM Device Token

Describe the bug
Is there a way to retrieve the device push notification token? Need to retrieve the token and save it.

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment

  • React Native version: 0.63.3
  • react-native-flurry-sdk version: 6.4.0
    Additional context
    Are you using Flurry Push/Messaging? Yes

Add any other context about the problem here.

Below Method "onTokenRefresh" gets fired before I can add a messaging listener, so the event is never triggered as sEnableMessagingListener false at that time.

@Override
        public void onTokenRefresh(String token) {
            if (sEnableMessagingListener && (sReactApplicationContext != null)) {
                sendEvent(EventType.TokenRefresh, token);
            }
        }

Error compiling after adding messaging with Android

Hello,

I am currently trying to set up messaging and I am running into an issue with Android. I was going through the set up and I am getting an error when trying to launch the app in my emulator. I get tihs error:

error: package FlurryModule does not exist
new FlurryModule.Builder()

I am currently running the lastest version of react native and the Flurry SDK.

This is what is in my MainApplication.java file

new FlurryModule.Builder()
.withCrashReporting(true)
.withMessaging(true) // optional user's native FlurryMarketingOptions or FlurryMessagingListener.
.build(this, apiKey);

Thanks in advanced.

Cannot read property 'initBuilder' of undefined

Hi, I tried to install this library and I faced this issue on iOS so I tried to use cocopods and it solved my problem, and now Im facing this error on android could you please tell me how can I manually link this library for android?
I'm using react native 0.59.6 and "react-native-flurry-sdk": "^4.1.0",

Reinitializing flurry on the fly

Describe the bug
This is not a bug, but rather a question. What would happen if I invoke Flurry.Builder() multiple times throughout the app with different api keys? Will flurry pickup the api key change and send events to a correct account?

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.62.2
  • react-native-flurry-sdk version: 5.5.0

library not found for -lReactNativeFlurry

Getting this error after going through installation.

ld: library not found for -lReactNativeFlurry clang: error: linker command failed with exit code 1 (use -v to see invocation)

  • The library is linked properly in xcode. (File added to Libraries + Link Binary with Libraries)
  • Using xcworkspace to run project.
  • React Native version: : "^0.57.5",
  • React Native Flurry Analytics works perfectly fine.

React/RCTDefines.h file not found

Hello,

I am trying to add this library on my project for two days and it is always getting failed.
I am using react-native: 0.57.1 and react-native-cli: 2.0.1
Please check about the screenshot below.

Regards,
Dima

screen shot 2018-12-10 at 11 42 51 am

Crashed: com.Flurry.Analytics.LogSender

Describe the bug
I have this crash on Crashlytics (iOS), I don't know how to reproduce it.

Crashed: com.Flurry.Analytics.LogSender
0  libobjc.A.dylib                0x1a2556474 objc_msgSend
1  x                              0x102c38280 -[FlurryDataSender retransmitNotSentBlocks] + 323 (FlurryDataSender.m:323)
2  x                              0x102c45434 -[FlurryDataSenderBase unregisterTask:completedSuccessfuly:] + 95 (FlurryDataSenderBase.m:95)
3  x                              0x102c380a0 -[FlurryDataSender requestSuccessComplete:withResponse:] + 305 (FlurryDataSender.m:305)
4  x                              0x102c37d6c __60-[FlurryDataSender flurryUrlRequestDidSucceed:withResponse:]_block_invoke + 271 (FlurryDataSender.m:271)
5  libdispatch.dylib              0x18de29298 _dispatch_call_block_and_release
6  libdispatch.dylib              0x18de2a280 _dispatch_client_callout
7  libdispatch.dylib              0x18ddd2dcc _dispatch_lane_serial_drain$VARIANT$mp
8  libdispatch.dylib              0x18ddd38a8 _dispatch_lane_invoke$VARIANT$mp
9  libdispatch.dylib              0x18dddd338 _dispatch_workloop_worker_thread
10 libsystem_pthread.dylib        0x1d68eb5a4 _pthread_wqthread
11 libsystem_pthread.dylib        0x1d68ee874 start_wqthread

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.63.3
  • react-native-flurry-sdk version: 6.1.0

To Reproduce
I have this crash on Crashlytics (iOS), I don't know how to reproduce it. Sorry.

Screenshots
From Crashlytics

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Stacktrace

Crashed: com.Flurry.Analytics.LogSender
0  libobjc.A.dylib                0x1a2556474 objc_msgSend
1  x                              0x102c38280 -[FlurryDataSender retransmitNotSentBlocks] + 323 (FlurryDataSender.m:323)
2  x                              0x102c45434 -[FlurryDataSenderBase unregisterTask:completedSuccessfuly:] + 95 (FlurryDataSenderBase.m:95)
3  x                              0x102c380a0 -[FlurryDataSender requestSuccessComplete:withResponse:] + 305 (FlurryDataSender.m:305)
4  x                              0x102c37d6c __60-[FlurryDataSender flurryUrlRequestDidSucceed:withResponse:]_block_invoke + 271 (FlurryDataSender.m:271)
5  libdispatch.dylib              0x18de29298 _dispatch_call_block_and_release
6  libdispatch.dylib              0x18de2a280 _dispatch_client_callout
7  libdispatch.dylib              0x18ddd2dcc _dispatch_lane_serial_drain$VARIANT$mp
8  libdispatch.dylib              0x18ddd38a8 _dispatch_lane_invoke$VARIANT$mp
9  libdispatch.dylib              0x18dddd338 _dispatch_workloop_worker_thread
10 libsystem_pthread.dylib        0x1d68eb5a4 _pthread_wqthread
11 libsystem_pthread.dylib        0x1d68ee874 start_wqthread

Device

  • Brand: Apple
  • Model: iPhone 6s Plus
  • iOS Version: 14.3.0 (18C66)

Could not resolve all files for configuration ':react-native-flurry-sdk:androidApis'

Describe the bug
Building android throws the following error:

FAILURE: Build failed with an exception.
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * What went wrong:
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Execution failed for task ':react-native-flurry-sdk:parseReleaseLocalResources'.
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Could not resolve all files for configuration ':react-native-flurry-sdk:androidApis'.
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Failed to transform android.jar to match attributes {artifactType=android-platform-attr, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}.
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Execution failed for PlatformAttrTransform: /Users/fabian/Library/Android/sdk/platforms/android-28/android.jar.
2022-04-11T16:39:48.082+0930 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > /Users/fabian/Library/Android/sdk/platforms/android-28/android.jar

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.66.4
  • react-native-flurry-sdk version: ^7.1.1

To Reproduce
Steps to reproduce the behavior:
yarn add react-native-flurry-sdk
then try to do an android build in the android directory with:
./gradlew assembleRelease

Add any other context about the problem here.
iOS integration is working fine for the same project.

How to use flurry for cumulative data like total amount of moneys users spent?

Hi, thank you for your perfect library, I need to know sum of money users spent daily on my app. how can I achieve that with your api's,
Also I want to log an event with more than one parameters so is this the write way?

 Flurry.logEvent(eventType, {itemType : eventParam , itemID : eventParam2, itemCost : eventParam3, itemCurrency : eventParam4})

Unable to instantiate service com.flurry.android.marketing.messaging.FCM.FlurryMessageListenerService: java.lang.ClassNotFoundException: Didn't find class

It looks like alongside my iOS issue, I have a somewhat similar problem with Android that was reported by our CI and Google Play's pre-launch report:

Screen Shot 2019-06-18 at 10 45 18

It's interesting that not all devices (only 7 out of 10) are affected.

As per my other issue, I'm not using push notifications, so have not followed any of the "FLurry Push" section of the Android setup instructions (e.g. didn't use .withMessaging() etc).


Note I didn't follow this step in the setup instructions as it seems to be optional:

To improve analytics identities, please see Manual Flurry Android SDK Integration for adding Google Play Services library in your app by including the following in your build.gradle file:

dependencies {
    // Recommended to add Google Play Services
    implementation 'com.google.android.gms:play-services-base:15.0.1'
    implementation 'com.google.android.gms:play-services-ads:15.0.1'
}

This one is obviously more serious than my iOS issue as it would stop us from releasing the update containing Flurry.

Thanks in advance!

logEvent does not save params

Describe the bug
I'm unsure if this is an issue with the library or with the dashboard.
I cant get events parameters to be logged, been trying for weeks now.

Flurry.logEvent('test_event', {'theparam': '1234'});

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Analytics
  • [?] Flurry Website/Dashboard

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • iOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.63.2
  • react-native-flurry-sdk version: 6.2.0

Fatal Exception: Package android does not belong to 10251

Describe the bug
I have this crash on Crashlytics (Android), I don't know how to reproduce it.

Fatal Exception: java.lang.SecurityException: Package android does not belong to 10251
       at android.os.Parcel.createExceptionOrNull(Parcel.java:2373)
       at android.os.Parcel.createException(Parcel.java:2357)
       at android.os.Parcel.readException(Parcel.java:2340)
       at android.os.Parcel.readException(Parcel.java:2282)
       at android.net.IConnectivityManager$Stub$Proxy.getNetworkCapabilities(IConnectivityManager.java:2456)
       at android.net.ConnectivityManager.getNetworkCapabilities(ConnectivityManager.java:1385)
       at com.flurry.sdk.av.getNetworkTypeM(SourceFile:518)
       at com.flurry.sdk.av.b(SourceFile:191)
       at com.flurry.sdk.av.c(SourceFile:418)
       at com.flurry.sdk.av.<init>(SourceFile:163)
       at com.flurry.sdk.n.<init>(SourceFile:1071)
       at com.flurry.sdk.n.a(SourceFile:48)
       at com.flurry.sdk.bn.<init>(SourceFile:43)
       at com.flurry.sdk.bs.<init>(SourceFile:24)
       at com.flurry.sdk.ey.<init>(SourceFile:38)
       at com.flurry.sdk.fb.<init>(SourceFile:1014)
       at com.flurry.sdk.fb.a(SourceFile:31)
       at com.flurry.android.FlurryAgent$Builder.build(SourceFile:2120)
       at com.flurry.android.reactnative.FlurryModule.build(FlurryModule.java:114)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
       at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:151)
       at com.facebook.react.bridge.queue.NativeRunnable.run(NativeRunnable.java)
       at android.os.Handler.handleCallback(Handler.java:938)
       at android.os.Handler.dispatchMessage(Handler.java:99)
       at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:27)
       at android.os.Looper.loop(Looper.java:223)
       at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:226)
       at java.lang.Thread.run(Thread.java:923)

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.63.4
  • react-native-flurry-sdk version: 6.2.0

To Reproduce
I have this crash on Crashlytics (Android), I don't know how to reproduce it. Sorry.

Screenshots
From Crashlytics

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Stacktrace

Fatal Exception: java.lang.SecurityException: Package android does not belong to 10251
       at android.os.Parcel.createExceptionOrNull(Parcel.java:2373)
       at android.os.Parcel.createException(Parcel.java:2357)
       at android.os.Parcel.readException(Parcel.java:2340)
       at android.os.Parcel.readException(Parcel.java:2282)
       at android.net.IConnectivityManager$Stub$Proxy.getNetworkCapabilities(IConnectivityManager.java:2456)
       at android.net.ConnectivityManager.getNetworkCapabilities(ConnectivityManager.java:1385)
       at com.flurry.sdk.av.getNetworkTypeM(SourceFile:518)
       at com.flurry.sdk.av.b(SourceFile:191)
       at com.flurry.sdk.av.c(SourceFile:418)
       at com.flurry.sdk.av.<init>(SourceFile:163)
       at com.flurry.sdk.n.<init>(SourceFile:1071)
       at com.flurry.sdk.n.a(SourceFile:48)
       at com.flurry.sdk.bn.<init>(SourceFile:43)
       at com.flurry.sdk.bs.<init>(SourceFile:24)
       at com.flurry.sdk.ey.<init>(SourceFile:38)
       at com.flurry.sdk.fb.<init>(SourceFile:1014)
       at com.flurry.sdk.fb.a(SourceFile:31)
       at com.flurry.android.FlurryAgent$Builder.build(SourceFile:2120)
       at com.flurry.android.reactnative.FlurryModule.build(FlurryModule.java:114)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
       at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:151)
       at com.facebook.react.bridge.queue.NativeRunnable.run(NativeRunnable.java)
       at android.os.Handler.handleCallback(Handler.java:938)
       at android.os.Handler.dispatchMessage(Handler.java:99)
       at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:27)
       at android.os.Looper.loop(Looper.java:223)
       at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:226)
       at java.lang.Thread.run(Thread.java:923)

Caused by android.os.RemoteException: Remote stack trace:
	at android.app.AppOpsManager.checkPackage(AppOpsManager.java:7698)
	at com.android.server.ConnectivityService.getNetworkCapabilities(ConnectivityService.java:1668)
	at android.net.IConnectivityManager$Stub.onTransact(IConnectivityManager.java:978)
	at android.os.Binder.execTransactInternal(Binder.java:1154)
	at android.os.Binder.execTransact(Binder.java:1123)

Device

  • Brand: Google
  • Model: Pixel 3 XL
  • Android Version: 11

problem with install CocoaPods

Describe the bug
A clear and concise description of what the bug is.
When I install react-native-flurry-sdk - have problem with installation pods for IOS. Also at readme and here in documentation(https://developer.yahoo.com/flurry/docs/integrateflurry/ios/). Wrote, that need add some code to "podfile", like this "pod 'Flurry-iOS-SDK/FlurrySDK' #Analytics Pod" or if you need push messages - "another code to podfile", but now "podfile" have another structure and you can't do this how I understand.
Also, I not yet tried to install previous version, may be it will work...

This Bug is About
Please choose the closest item by replacing [ ] with [x].

  • Integration
  • Analytics
  • Messaging/Push
  • Remote Configuration
  • Flurry Website/Dashboard
  • Other

Platform
Please choose the platform(s) that you are having the issue by replacing [ ] with [x].

  • Android
  • iOS
  • tvOS

Environment
Please tell us the versions of SDKs you are using. If you are not sure about React Native version, you can run react-native --version under your project.

  • React Native version: 0.64.2
  • react-native-flurry-sdk version: 7.1.1

To Reproduce
Steps to reproduce the behavior:

  1. install react-native-flurry-sdk, and write pod install at ios folder.
  2. ...
  3. ...

Screenshots
If applicable, add screenshots to help explain your problem.
Screenshot 2022-01-13 at 15 20 21
Screenshot 2022-01-13 at 15 20 37
Screenshot 2022-01-13 at 15 20 46
Screenshot 2022-01-13 at 15 20 58

Additional context
Are you using Flurry Push/Messaging? No
(iOS) Are you using CocoaPods for React Native integration? Yes

Add any other context about the problem here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.