Skip to content

REPLAY-1905 Do not resolve WindowManager from Application context#1558

Merged
mariusc83 merged 1 commit into
developfrom
mconstantin/replay-1905/do-not-use-the-windowmanager-in-background-thread
Jul 28, 2023
Merged

REPLAY-1905 Do not resolve WindowManager from Application context#1558
mariusc83 merged 1 commit into
developfrom
mconstantin/replay-1905/do-not-use-the-windowmanager-in-background-thread

Conversation

@mariusc83

Copy link
Copy Markdown
Member

What does this PR do?

In this PR we are fixing the StrictMode IllegalAccesException when trying to get the WindowManager from the Application instead of getting it from a visual Context as recommended.

Motivation

What inspired you to submit this pull request?

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)

@mariusc83 mariusc83 self-assigned this Jul 28, 2023
@mariusc83
mariusc83 force-pushed the mconstantin/replay-1905/do-not-use-the-windowmanager-in-background-thread branch 2 times, most recently from 847a8f1 to 4212965 Compare July 28, 2023 11:45
@mariusc83
mariusc83 force-pushed the mconstantin/replay-1905/do-not-use-the-windowmanager-in-background-thread branch from 4212965 to d943db3 Compare July 28, 2023 11:47
@mariusc83
mariusc83 marked this pull request as ready for review July 28, 2023 11:48
@mariusc83
mariusc83 requested a review from a team as a code owner July 28, 2023 11:48
@codecov-commenter

codecov-commenter commented Jul 28, 2023

Copy link
Copy Markdown

Codecov Report

Merging #1558 (d943db3) into develop (5c9feb9) will increase coverage by 0.10%.
Report is 6 commits behind head on develop.
The diff coverage is 92.86%.

@@             Coverage Diff             @@
##           develop    #1558      +/-   ##
===========================================
+ Coverage    83.21%   83.30%   +0.10%     
===========================================
  Files          437      437              
  Lines        14749    14750       +1     
  Branches      2220     2223       +3     
===========================================
+ Hits         12272    12287      +15     
+ Misses        1889     1873      -16     
- Partials       588      590       +2     
Files Changed Coverage Δ
...nternal/recorder/listener/WindowsOnDrawListener.kt 89.29% <85.71%> (-6.71%) ⬇️
...dog/android/sessionreplay/SessionReplayRecorder.kt 94.20% <100.00%> (ø)
...nreplay/internal/recorder/ViewOnDrawInterceptor.kt 95.83% <100.00%> (-0.17%) ⬇️
...ternal/recorder/callback/RecorderWindowCallback.kt 90.48% <100.00%> (-0.15%) ⬇️

... and 19 files with indirect coverage changes

@mariusc83
mariusc83 merged commit 08ec188 into develop Jul 28, 2023
@mariusc83
mariusc83 deleted the mconstantin/replay-1905/do-not-use-the-windowmanager-in-background-thread branch July 28, 2023 12:14
@xgouchet xgouchet added this to the 2.1.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.

4 participants