Skip to content

Conversation

itaybre
Copy link
Contributor

@itaybre itaybre commented Sep 2, 2025

#skip-changelog

Copy link

linear bot commented Sep 2, 2025

Copy link

codecov bot commented Sep 2, 2025

Codecov Report

❌ Patch coverage is 94.81132% with 11 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.693%. Comparing base (5840d2d) to head (5dffa26).
⚠️ Report is 13 commits behind head on main.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
Sources/Swift/SentryCrash/SentryCrashWrapper.swift 94.472% 11 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@              Coverage Diff              @@
##              main     #6047       +/-   ##
=============================================
+ Coverage   86.625%   86.693%   +0.068%     
=============================================
  Files          435       435               
  Lines        36980     37057       +77     
  Branches     17390     17397        +7     
=============================================
+ Hits         32034     32126       +92     
+ Misses        4900      4886       -14     
+ Partials        46        45        -1     
Files with missing lines Coverage Δ
Sources/Sentry/SentryANRTrackerV1.m 99.212% <ø> (ø)
Sources/Sentry/SentryANRTrackerV2.m 98.863% <ø> (ø)
Sources/Sentry/SentryANRTrackingIntegration.m 98.809% <ø> (ø)
Sources/Sentry/SentryAppStartTrackingIntegration.m 100.000% <ø> (ø)
Sources/Sentry/SentryAppStateManager.m 100.000% <ø> (ø)
Sources/Sentry/SentryBaseIntegration.m 95.512% <ø> (ø)
Sources/Sentry/SentryCrashIntegration.m 99.200% <100.000%> (ø)
...rces/Sentry/SentryCrashIntegrationSessionHandler.m 100.000% <ø> (ø)
Sources/Sentry/SentryCrashReportSink.m 90.909% <ø> (ø)
Sources/Sentry/SentryDependencyContainer.m 89.495% <100.000%> (-0.044%) ⬇️
... and 10 more

... and 8 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5840d2d...5dffa26. Read the comment docs.

Copy link
Contributor

github-actions bot commented Sep 2, 2025

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1211.06 ms 1231.58 ms 20.52 ms
Size 23.75 KiB 971.22 KiB 947.47 KiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
f262e10 1226.88 ms 1250.39 ms 23.51 ms
9450cb4 1221.29 ms 1232.96 ms 11.67 ms
76f74df 1238.29 ms 1261.22 ms 22.94 ms
a3dfd57 1230.78 ms 1244.91 ms 14.14 ms
2a7868a 1226.54 ms 1256.92 ms 30.37 ms
9e6569a 1216.07 ms 1242.50 ms 26.43 ms
924de23 1222.84 ms 1248.37 ms 25.54 ms
891fd1d 1220.02 ms 1227.60 ms 7.57 ms
50a9ff7 1221.43 ms 1238.07 ms 16.64 ms
2609f7a 1218.17 ms 1241.34 ms 23.17 ms

App size

Revision Plain With Sentry Diff
f262e10 23.75 KiB 913.62 KiB 889.87 KiB
9450cb4 23.75 KiB 908.55 KiB 884.80 KiB
76f74df 23.75 KiB 879.61 KiB 855.86 KiB
a3dfd57 23.75 KiB 913.63 KiB 889.87 KiB
2a7868a 23.75 KiB 880.20 KiB 856.45 KiB
9e6569a 23.75 KiB 904.54 KiB 880.79 KiB
924de23 23.75 KiB 947.54 KiB 923.79 KiB
891fd1d 23.75 KiB 919.92 KiB 896.17 KiB
50a9ff7 23.75 KiB 913.63 KiB 889.89 KiB
2609f7a 23.75 KiB 867.04 KiB 843.29 KiB

Previous results on branch: itay/cocoa-551-convert-sentrycrashwrapper-to-swift

Startup times

Revision Plain With Sentry Diff
4290f04 1217.52 ms 1236.62 ms 19.10 ms
d7566e2 1205.94 ms 1236.04 ms 30.10 ms
df16a98 1208.71 ms 1219.46 ms 10.75 ms
228338d 1225.35 ms 1246.90 ms 21.55 ms
aaefa73 1217.06 ms 1242.94 ms 25.88 ms
06c7c9c 1223.06 ms 1248.71 ms 25.64 ms

App size

Revision Plain With Sentry Diff
4290f04 23.75 KiB 936.73 KiB 912.98 KiB
d7566e2 23.75 KiB 941.63 KiB 917.88 KiB
df16a98 23.75 KiB 941.67 KiB 917.92 KiB
228338d 23.75 KiB 971.16 KiB 947.41 KiB
aaefa73 23.75 KiB 962.91 KiB 939.15 KiB
06c7c9c 23.75 KiB 971.13 KiB 947.38 KiB

@itaybre itaybre marked this pull request as ready for review September 3, 2025 18:35
Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

I'm a bit afraid that we introduce new bugs with this refactoring cause the test coverage for the SentryCrashWrapper is quite limited.

cursor[bot]

This comment was marked as outdated.

Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

I maybe found a few issues and a bug. I think we must capture messages before this refactoring on different platforms and compare the event context properties to ensure we didn't mess anything up about the enrichScope method. Otherwise, I'm afraid we introduce bugs.

Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

The only thing stopping me from approving this PR is

I think we must capture messages before this refactoring on different platforms and compare the event context properties to ensure we didn't mess anything up about the enrichScope method. Otherwise, I'm afraid we introduce bugs.

It would be great if you could do that and post the test results with screenshots and links to the events in Sentry here.

@itaybre
Copy link
Contributor Author

itaybre commented Sep 11, 2025

macOS:

Before After
image image

iOS:

Before After
image image

Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

Thanks for the multiple rounds of feedback, testing it manually and finally getting it ready to merge, @itaybre 💯

@itaybre itaybre merged commit 8745cc0 into main Sep 12, 2025
204 of 211 checks passed
@itaybre itaybre deleted the itay/cocoa-551-convert-sentrycrashwrapper-to-swift branch September 12, 2025 13:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants