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: only start frame tracking if we receive valid refresh data #2307

Merged
merged 12 commits into from
Sep 25, 2024

Conversation

buenaflor
Copy link
Contributor

@buenaflor buenaflor commented Sep 25, 2024

📜 Description

Refresh data should not be null and bigger than 0

💡 Motivation and Context

Fixes frame tracking being started with invalid display refresh data

💚 How did you test it?

Unit test

📝 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
  • I updated the docs if needed
  • All tests passing
  • No breaking changes

🔮 Next steps

Copy link

codecov bot commented Sep 25, 2024

Codecov Report

Attention: Patch coverage is 77.77778% with 2 lines in your changes missing coverage. Please review.

Project coverage is 90.80%. Comparing base (b66cc27) to head (c67205b).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
flutter/lib/src/span_frame_metrics_collector.dart 77.77% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2307      +/-   ##
==========================================
+ Coverage   88.09%   90.80%   +2.71%     
==========================================
  Files         247       73     -174     
  Lines        8593     2382    -6211     
==========================================
- Hits         7570     2163    -5407     
+ Misses       1023      219     -804     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

github-actions bot commented Sep 25, 2024

Android Performance metrics 🚀

  Plain With Sentry Diff
Startup time 465.42 ms 508.20 ms 42.78 ms
Size 6.49 MiB 7.56 MiB 1.07 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
4d75417 421.23 ms 454.41 ms 33.18 ms
84bc635 395.57 ms 464.23 ms 68.66 ms
c57d3b7 413.56 ms 508.80 ms 95.24 ms
ebfead1 298.44 ms 374.28 ms 75.84 ms
26e955b 369.52 ms 458.60 ms 89.07 ms
9c5aec6 287.33 ms 320.94 ms 33.61 ms
e82709a 361.18 ms 423.50 ms 62.32 ms
2e1e4ae 413.34 ms 509.24 ms 95.90 ms
2d4fd8b 376.67 ms 456.88 ms 80.21 ms
895becc 326.94 ms 376.02 ms 49.08 ms

App size

Revision Plain With Sentry Diff
4d75417 6.52 MiB 7.59 MiB 1.06 MiB
84bc635 6.34 MiB 7.28 MiB 968.41 KiB
c57d3b7 6.33 MiB 7.30 MiB 992.08 KiB
ebfead1 6.06 MiB 7.03 MiB 989.24 KiB
26e955b 6.27 MiB 7.20 MiB 956.49 KiB
9c5aec6 5.94 MiB 6.92 MiB 1001.61 KiB
e82709a 6.34 MiB 7.29 MiB 970.37 KiB
2e1e4ae 6.35 MiB 7.42 MiB 1.06 MiB
2d4fd8b 6.27 MiB 7.20 MiB 958.59 KiB
895becc 6.06 MiB 7.03 MiB 997.23 KiB

Previous results on branch: fix/error-invalid-refreshrate

Startup times

Revision Plain With Sentry Diff
4267f4d 459.31 ms 493.46 ms 34.15 ms
fd3cc73 459.26 ms 496.33 ms 37.07 ms
8faca71 473.83 ms 522.47 ms 48.64 ms
42e2c7c 570.14 ms 663.90 ms 93.76 ms
898d8d6 490.53 ms 518.60 ms 28.07 ms

App size

Revision Plain With Sentry Diff
4267f4d 6.49 MiB 7.56 MiB 1.07 MiB
fd3cc73 6.49 MiB 7.56 MiB 1.07 MiB
8faca71 6.49 MiB 7.56 MiB 1.07 MiB
42e2c7c 6.49 MiB 7.56 MiB 1.07 MiB
898d8d6 6.49 MiB 7.56 MiB 1.07 MiB

Copy link
Contributor

github-actions bot commented Sep 25, 2024

iOS Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1257.78 ms 1278.82 ms 21.04 ms
Size 8.38 MiB 9.74 MiB 1.36 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
178baee 1230.61 ms 1249.94 ms 19.33 ms
7b2e0ad 1246.92 ms 1275.22 ms 28.31 ms
86d4841 1225.69 ms 1241.12 ms 15.43 ms
5e8d2b3 1255.71 ms 1267.98 ms 12.27 ms
2e93bab 1237.08 ms 1258.41 ms 21.33 ms
3f3ef0b 1223.73 ms 1237.67 ms 13.94 ms
8932ece 1234.31 ms 1238.90 ms 4.59 ms
f922f8f 1249.53 ms 1266.51 ms 16.98 ms
d4120ac 1260.61 ms 1274.09 ms 13.47 ms
9d7e862 1236.88 ms 1258.62 ms 21.74 ms

App size

Revision Plain With Sentry Diff
178baee 8.34 MiB 9.67 MiB 1.33 MiB
7b2e0ad 8.38 MiB 9.73 MiB 1.35 MiB
86d4841 8.29 MiB 9.36 MiB 1.07 MiB
5e8d2b3 8.29 MiB 9.36 MiB 1.07 MiB
2e93bab 8.38 MiB 9.73 MiB 1.36 MiB
3f3ef0b 8.32 MiB 9.38 MiB 1.05 MiB
8932ece 8.29 MiB 9.36 MiB 1.07 MiB
f922f8f 8.15 MiB 9.13 MiB 1003.20 KiB
d4120ac 8.28 MiB 9.34 MiB 1.06 MiB
9d7e862 8.32 MiB 9.38 MiB 1.05 MiB

Previous results on branch: fix/error-invalid-refreshrate

Startup times

Revision Plain With Sentry Diff
fd3cc73 1246.08 ms 1268.42 ms 22.33 ms
4267f4d 1240.90 ms 1254.84 ms 13.94 ms
8faca71 1248.96 ms 1283.98 ms 35.02 ms
898d8d6 1246.53 ms 1260.70 ms 14.17 ms
42e2c7c 1236.65 ms 1268.95 ms 32.30 ms

App size

Revision Plain With Sentry Diff
fd3cc73 8.38 MiB 9.74 MiB 1.36 MiB
4267f4d 8.38 MiB 9.74 MiB 1.36 MiB
8faca71 8.38 MiB 9.74 MiB 1.36 MiB
898d8d6 8.38 MiB 9.74 MiB 1.36 MiB
42e2c7c 8.38 MiB 9.74 MiB 1.36 MiB

@buenaflor buenaflor changed the title Only start frame tracking if we receive valid refresh data fix: only start frame tracking if we receive valid refresh data Sep 25, 2024
@kahest
Copy link
Member

kahest commented Sep 25, 2024

does this supercede #2299?

Copy link
Member

@kahest kahest left a comment

Choose a reason for hiding this comment

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

left 2 questions to clarify, otherwise LGTM

flutter/lib/src/span_frame_metrics_collector.dart Outdated Show resolved Hide resolved
@buenaflor
Copy link
Contributor Author

does this supercede #2299?

yep, the other PR is not applicable anymore since we don't want to use a default refresh rate

@buenaflor buenaflor merged commit bf8d36c into main Sep 25, 2024
49 checks passed
@buenaflor buenaflor deleted the fix/error-invalid-refreshrate branch September 25, 2024 22:47
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