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-3180: Avoid crash when applicationContext is null #1864

Merged

Conversation

jonathanmos
Copy link
Contributor

What does this PR do?

If applicationContext is null when performing createImageWireframe, then log the view to telemetry and return null from the method

Motivation

Fixes issue where a NPE crash was seen on applicationContext

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 changed the title RUM-3180: Avoid crash when applicationcontext is null RUM-3180: Avoid crash when applicationContext is null Feb 20, 2024
@codecov-commenter
Copy link

codecov-commenter commented Feb 20, 2024

Codecov Report

Merging #1864 (cf58dc5) into develop (659c865) will decrease coverage by 0.25%.
Report is 2 commits behind head on develop.
The diff coverage is 100.00%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1864      +/-   ##
===========================================
- Coverage    83.72%   83.47%   -0.25%     
===========================================
  Files          470      470              
  Lines        16629    16603      -26     
  Branches      2499     2495       -4     
===========================================
- Hits         13922    13859      -63     
- Misses        2042     2060      +18     
- Partials       665      684      +19     
Files Coverage Δ
...adog/android/sessionreplay/SessionReplayPrivacy.kt 100.00% <100.00%> (ø)
...dog/android/sessionreplay/SessionReplayRecorder.kt 94.74% <100.00%> (ø)
...y/internal/recorder/base64/ImageWireframeHelper.kt 95.20% <100.00%> (+0.28%) ⬆️

... and 23 files with indirect coverage changes

@jonathanmos jonathanmos marked this pull request as ready for review February 20, 2024 10:14
@jonathanmos jonathanmos requested review from a team as code owners February 20, 2024 10:14
@jonathanmos jonathanmos merged commit 595d19e into develop Feb 20, 2024
23 checks passed
@jonathanmos jonathanmos deleted the jmoskovich/rum-3180/handle-null-applicationcontext branch February 20, 2024 12:17
@xgouchet xgouchet added this to the 2.7.0 milestone Apr 5, 2024
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.

None yet

4 participants