Skip to content

RUM-1189 fix duplicate views in MixedViewTrackingStrategy#1639

Merged
xgouchet merged 1 commit into
developfrom
xgouchet/RUM-1189/duplicate_views
Sep 26, 2023
Merged

RUM-1189 fix duplicate views in MixedViewTrackingStrategy#1639
xgouchet merged 1 commit into
developfrom
xgouchet/RUM-1189/duplicate_views

Conversation

@xgouchet

Copy link
Copy Markdown
Contributor

What does this PR do?

Fix #1614

Because the inner Activity and Fragment ViewTrackingStrategies used by the MixedViewTrackingStrategy also listen to activity lifecycle callbacks, RUM start view events are called twice, resulting in duplicated events.

@xgouchet
xgouchet requested a review from a team as a code owner September 25, 2023 14:03
@xgouchet
xgouchet force-pushed the xgouchet/RUM-1189/duplicate_views branch from fae9dd4 to 3653664 Compare September 25, 2023 15:40
@codecov-commenter

codecov-commenter commented Sep 25, 2023

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.64%. Comparing base (99c47fb) to head (3653664).
⚠️ Report is 2486 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1639      +/-   ##
===========================================
- Coverage    83.72%   83.64%   -0.07%     
===========================================
  Files          456      456              
  Lines        15716    15695      -21     
  Branches      2340     2339       -1     
===========================================
- Hits         13157    13128      -29     
- Misses        1927     1941      +14     
+ Partials       632      626       -6     
Files with missing lines Coverage Δ
.../android/rum/tracking/MixedViewTrackingStrategy.kt 81.48% <ø> (-7.41%) ⬇️

... and 24 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.


// region ActivityLifecycleTrackingStrategy

override fun register(sdkCore: SdkCore, context: Context) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this was brought with the sdk v2 as before we did not register the strategies.

@xgouchet
xgouchet merged commit 2d15670 into develop Sep 26, 2023
@xgouchet
xgouchet deleted the xgouchet/RUM-1189/duplicate_views branch September 26, 2023 09:37
@xgouchet xgouchet added this to the 2.2.0 milestone Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

View's duplicated when using version 2.x

3 participants