Skip to content

Received crashes from Firebase's AI guided tests crashlytics from BranchActivityLifecycleObserver.onResume #1277

Open
@OgnjenCC

Description

@OgnjenCC

Describe the bug

We have been receiving crashes in batches regarding the initialization of the Branch SDK.
This is what we receive:

          Caused by java.lang.NullPointerException: Attempt to invoke virtual method 'android.os.Parcelable android.content.Intent.getParcelableExtra(java.lang.String)' on a null object reference
       at android.app.Activity.getReferrer(Activity.java:6111)
       at androidx.core.app.ActivityCompat$Api22Impl.getReferrer(ActivityCompat.java:879)
       at androidx.core.app.ActivityCompat.getReferrer(ActivityCompat.java:329)
       at io.branch.referral.Branch$InitSessionBuilder.init(Branch.java:2444)
       at io.branch.referral.BranchActivityLifecycleObserver.onActivityResumed(BranchActivityLifecycleObserver.java:70)
       at android.app.Application.dispatchActivityResumed(Application.java:455)
       at android.app.Activity.dispatchActivityResumed(Activity.java:1291)
       at android.app.Activity.onResume(Activity.java:1819)
       at androidx.fragment.app.FragmentActivity.onResume(FragmentActivity.java:309)
       at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1454)
       at android.app.Activity.performResume(Activity.java:8111)
       at android.app.ActivityThread.performResumeActivity(ActivityThread.java:4647)
       at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:4690)
       at android.app.servertransaction.ResumeActivityItem.execute(ResumeActivityItem.java:52)

  • Crashes happens on Android API lvl 30 or less

  • We followed everything step by step from the documentation basic setup.

  • We are still not using branch links, these crashes come from installs/app starts.

Image

Steps to reproduce

Run AI guided tests on Firebase

Expected behavior

App does not crash

SDK Version

5.17.0

Make and Model

Any model from Firebase A&B testing

OS

any OS - but most are on Android 11

Additional Information/Context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions