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

Fix potential SecurityException thrown by ConnectivityManager on Android 11 #2653

Merged
merged 3 commits into from
Apr 17, 2023

Conversation

markushi
Copy link
Member

📜 Description

Retrieving Network info via ConnectivityManager seems to cause crashes on Android 11. See https://issuetracker.google.com/issues/175055271 for more details.

💡 Motivation and Context

Fixes #2646

💚 How did you test it?

Added new unit tests

📝 Checklist

  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.

🔮 Next steps

@github-actions
Copy link
Contributor

github-actions bot commented Apr 15, 2023

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 351.38 ms 395.50 ms 44.12 ms
Size 1.73 MiB 2.26 MiB 550.35 KiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
33c80c7 318.88 ms 348.14 ms 29.26 ms
17ab223 427.65 ms 484.31 ms 56.65 ms
d81684e 235.73 ms 328.76 ms 93.03 ms
33c80c7 331.94 ms 370.54 ms 38.60 ms

App size

Revision Plain With Sentry Diff
33c80c7 1.73 MiB 2.26 MiB 551.46 KiB
17ab223 1.73 MiB 2.34 MiB 626.85 KiB
d81684e 1.73 MiB 2.26 MiB 547.78 KiB
33c80c7 1.73 MiB 2.26 MiB 551.46 KiB

@codecov
Copy link

codecov bot commented Apr 15, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (0686640) 81.39% compared to head (d58406b) 81.39%.

Additional details and impacted files
@@            Coverage Diff            @@
##               main    #2653   +/-   ##
=========================================
  Coverage     81.39%   81.39%           
  Complexity     4227     4227           
=========================================
  Files           337      337           
  Lines         15622    15622           
  Branches       2039     2039           
=========================================
  Hits          12715    12715           
  Misses         2112     2112           
  Partials        795      795           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@markushi markushi merged commit 003076d into main Apr 17, 2023
17 checks passed
@markushi markushi deleted the fix/network-securityexception branch April 17, 2023 05:37
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.

SecurityException when call sentry.init in some Android 11
2 participants