react-native-branch-deep-linking-attribution icon indicating copy to clipboard operation
react-native-branch-deep-linking-attribution copied to clipboard

Session initialization already happened.

Open kaixuannnn opened this issue 3 years ago • 3 comments

I had this issue in my project. Session initialization already happened. To force a new session, se intent extra, 'branch_force_new_session', to true.

I am using branch to retrieve some params and openURL while opening a notification outside an app. It works fine when I already killed the app. The branch able to open URL. However, it showed error(error message above) and branch.openURL not working when I didnt kill the app.

Below is my MainActivity.java. Screenshot 2021-04-09 at 10 57 43 AM

Thank you.

kaixuannnn avatar Apr 09 '21 02:04 kaixuannnn

any updates?

hsavit1 avatar Apr 14 '21 13:04 hsavit1

Please add below method in MainActivity.java class

@Override protected void onRestart() {
super.onRestart(); Intent intent = getIntent(); setIntent(intent); intent.putExtras(this.getIntent()); intent.putExtra("branch_force_new_session", true); }

RajeshRRathod avatar May 12 '21 15:05 RajeshRRathod

Also seeing this one occasionally in our app. Not sure exactly when or why it's happening either. With the random "trouble reaching branch servers" and "session initialization already happened" Branch seems really unreliable. This SDK seems to fail more often than it works on Android.

evelant avatar Jun 22 '21 20:06 evelant