Closed Asgaroth closed 2 years ago
Hi Alex, thanks for the report. We have a repro and we are working on a fix!
Note that I'm also seeing the userId missing from a screen call immediately following the identify as well.
analytics-react-native version: 2.2.2
Bit different use case but the incorrect behaviour seem to be consistent with what has been described above.
We have scenario where we switch user profile and we trigger Identify call right after the profile has been switched. Observed data indicates that track event capturing the switch action (which is triggered at the same time or milliseconds apart as Identify call) is attributed to previous user ID, while an event triggered say 2 seconds after has proper user ID coming from the switched profile.
In our case the workaround with adding a delay will be ugly and will delay the whole app navigation for a solid 1 second, impacting UX.
Fixed in analytics-react-native 2.5.0
Please let us know if you run into any other issues
@alanjcharles we still see this problem in 2.10.0, was it really fixed or has it resurfaced?
or is it expected/mandatory to do await identify in order for next track call to have the userid ? which seems strange, identify shouldnt be blocking ?
@OskarAtJoint thanks for the report, this is not expected. While you can await
for a particular event, it shouldn't be required for userId to be updated. I just figured out the issue with this. Will be fixed in the next release.
ok! any idea of when that next release will come?!
analytics-react-native
version:2.3.1
0.3.3
0.64.3
Steps to reproduce
Do an
identify
call immediately followed by atrack
callExpected behavior
The
track
call should have auserId
propertyActual behavior
The
track
call acts as if the user were still anonymous.Adding a delay after the
identify
works as expected