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(ios): Only store envelopes of fatal crashes on iOS #3051

Merged
merged 2 commits into from
May 8, 2023

Conversation

krystofwoldrich
Copy link
Member

📢 Type of change

  • Bugfix

📜 Description

The way the option was checked, it only worked in a way flag was present or not, it didn't check the actual value.

💡 Motivation and Context

💚 How did you test it?

sample app

📝 Checklist

  • I reviewed submitted code
  • I added tests to verify changes
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled
  • All tests passing
  • No breaking changes

🔮 Next steps

@github-actions
Copy link
Contributor

github-actions bot commented May 8, 2023

Android (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 331.12 ms 343.16 ms 12.04 ms
Size 17.73 MiB 19.76 MiB 2.03 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
76d1baf+dirty 335.72 ms 355.52 ms 19.80 ms
80b2ce3 385.02 ms 387.36 ms 2.34 ms
15c80ab+dirty 336.27 ms 350.58 ms 14.31 ms
d197b5c+dirty 338.94 ms 354.87 ms 15.93 ms
86d6d2c+dirty 332.90 ms 352.45 ms 19.55 ms
acadc0f+dirty 373.24 ms 381.51 ms 8.27 ms
52a8031+dirty 311.55 ms 321.37 ms 9.82 ms
70caa60+dirty 299.00 ms 321.02 ms 22.02 ms
b1e8712 462.11 ms 465.71 ms 3.60 ms
d0bf494+dirty 375.37 ms 395.14 ms 19.77 ms

App size

Revision Plain With Sentry Diff
76d1baf+dirty 17.73 MiB 20.04 MiB 2.31 MiB
80b2ce3 17.73 MiB 19.75 MiB 2.02 MiB
15c80ab+dirty 17.73 MiB 20.04 MiB 2.31 MiB
d197b5c+dirty 17.73 MiB 20.04 MiB 2.31 MiB
86d6d2c+dirty 17.73 MiB 20.04 MiB 2.31 MiB
acadc0f+dirty 17.73 MiB 19.75 MiB 2.01 MiB
52a8031+dirty 17.73 MiB 20.04 MiB 2.31 MiB
70caa60+dirty 17.73 MiB 19.75 MiB 2.01 MiB
b1e8712 17.73 MiB 19.75 MiB 2.02 MiB
d0bf494+dirty 17.73 MiB 19.75 MiB 2.02 MiB

@github-actions
Copy link
Contributor

github-actions bot commented May 8, 2023

iOS (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1262.43 ms 1274.98 ms 12.55 ms
Size 2.36 MiB 2.85 MiB 495.51 KiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
76d1baf+dirty 1244.10 ms 1268.52 ms 24.42 ms
15c80ab+dirty 1223.74 ms 1228.96 ms 5.22 ms
d197b5c+dirty 1217.61 ms 1242.66 ms 25.05 ms
86d6d2c+dirty 1267.55 ms 1286.21 ms 18.66 ms
acadc0f+dirty 1264.38 ms 1290.06 ms 25.68 ms
52a8031+dirty 1280.88 ms 1289.78 ms 8.90 ms
70caa60+dirty 1218.27 ms 1230.30 ms 12.03 ms
d0bf494+dirty 1289.40 ms 1298.40 ms 9.00 ms
d7401ac+dirty 1252.38 ms 1275.04 ms 22.66 ms
80b2ce3+dirty 1265.92 ms 1268.60 ms 2.69 ms

App size

Revision Plain With Sentry Diff
76d1baf+dirty 2.36 MiB 2.82 MiB 469.45 KiB
15c80ab+dirty 2.36 MiB 2.83 MiB 474.49 KiB
d197b5c+dirty 2.36 MiB 2.82 MiB 462.86 KiB
86d6d2c+dirty 2.36 MiB 2.82 MiB 462.82 KiB
acadc0f+dirty 2.36 MiB 2.83 MiB 480.37 KiB
52a8031+dirty 2.36 MiB 2.82 MiB 469.44 KiB
70caa60+dirty 2.36 MiB 2.83 MiB 479.27 KiB
d0bf494+dirty 2.36 MiB 2.83 MiB 481.15 KiB
d7401ac+dirty 2.36 MiB 2.83 MiB 481.14 KiB
80b2ce3+dirty 2.36 MiB 2.84 MiB 486.98 KiB

@@ -319,7 +319,7 @@ - (void)setEventEnvironmentTag:(SentryEvent *)event
#if DEBUG
[PrivateSentrySDKOnly captureEnvelope:envelope];
#else
if (options[@"store"]) {
if ([[options objectForKey:@"store"] boolValue]) {
Copy link
Contributor

Choose a reason for hiding this comment

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

If store does not exist, will boolValue break anything?

Copy link
Member Author

Choose a reason for hiding this comment

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

No, it will be resolved to NO/false which is what I want.
I had the same thought but checked it.

@krystofwoldrich krystofwoldrich merged commit 241b7c2 into main May 8, 2023
@krystofwoldrich krystofwoldrich deleted the kw-fix-only-store-fatal-ios branch May 8, 2023 17:13
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.

2 participants