Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RUM-6218: Add privacy override for hidden views #2291

Merged

Conversation

jonathanmos
Copy link
Member

@jonathanmos jonathanmos commented Sep 26, 2024

What does this PR do?

Sets up the common mechanism for privacy overrides and implements overriding view privacy to hidden in the hierarchy.

Views will be able to set hidden override privacy using the api:
[view].setSessionReplayHidden(hide = true/false)
where true will register the view to be replaced with a placeholder with the label "Hidden", and false will remove the hidden override from the view. The children of hidden views will not be traversed.

Motivation

This is part of the third stage of Fine Grained Masking. The first stage was the start/stop api, and the second was global fine grained masking levels for the app.

Additional Notes

Anything else we should know when reviewing?

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch 3 times, most recently from de3f7ed to f466427 Compare September 26, 2024 11:58
@codecov-commenter
Copy link

codecov-commenter commented Sep 26, 2024

Codecov Report

Attention: Patch coverage is 86.20690% with 4 lines in your changes missing coverage. Please review.

Project coverage is 70.33%. Comparing base (4cc5caf) to head (f16a5d4).
Report is 12 commits behind head on develop.

Files with missing lines Patch % Lines
...ssionreplay/internal/recorder/TreeViewTraversal.kt 42.86% 3 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2291      +/-   ##
===========================================
+ Coverage    70.31%   70.33%   +0.02%     
===========================================
  Files          736      738       +2     
  Lines        27456    27493      +37     
  Branches      4606     4610       +4     
===========================================
+ Hits         19305    19337      +32     
- Misses        6862     6873      +11     
+ Partials      1289     1283       -6     
Files with missing lines Coverage Δ
...android/sessionreplay/PrivacyOverrideExtensions.kt 100.00% <100.00%> (ø)
...nreplay/internal/recorder/SessionReplayRecorder.kt 96.99% <100.00%> (+0.07%) ⬆️
...eplay/internal/recorder/mapper/HiddenViewMapper.kt 100.00% <100.00%> (ø)
...ssionreplay/internal/recorder/TreeViewTraversal.kt 89.47% <42.86%> (-6.60%) ⬇️

... and 32 files with indirect coverage changes

@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch 4 times, most recently from bb60c2e to 601398b Compare September 29, 2024 12:42
@jonathanmos jonathanmos marked this pull request as ready for review September 29, 2024 15:10
@jonathanmos jonathanmos requested review from a team as code owners September 29, 2024 15:10
@jonathanmos jonathanmos marked this pull request as draft October 2, 2024 13:32
@jonathanmos jonathanmos changed the title RUM-6218: Add privacy override for hidden views (WIP) RUM-6218: Add privacy override for hidden views Oct 2, 2024
@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch 6 times, most recently from 9a71fee to 97b9bc9 Compare October 7, 2024 08:32
@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch from 97b9bc9 to 11ed3d1 Compare October 7, 2024 08:34
@jonathanmos jonathanmos changed the title (WIP) RUM-6218: Add privacy override for hidden views RUM-6218: Add privacy override for hidden views Oct 7, 2024
@jonathanmos jonathanmos marked this pull request as ready for review October 7, 2024 08:50
@jonathanmos jonathanmos requested a review from 0xnm October 7, 2024 08:56
@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch from fa68b66 to b6fb5c1 Compare October 9, 2024 17:50
@jonathanmos jonathanmos force-pushed the jmoskovich/rum-6218/implement-hidden-privacy-override branch from 715c7b1 to f16a5d4 Compare October 14, 2024 07:57
Copy link
Member

@ambushwork ambushwork left a comment

Choose a reason for hiding this comment

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

LGTM, well done!

@jonathanmos jonathanmos merged commit 25f9a39 into develop Oct 14, 2024
23 checks passed
@jonathanmos jonathanmos deleted the jmoskovich/rum-6218/implement-hidden-privacy-override branch October 14, 2024 08:48
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.

6 participants