Skip to content

chore: app start time improvement (#WPB-14874) #4041

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

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

sbakhtiarov
Copy link
Contributor

@sbakhtiarov sbakhtiarov commented May 27, 2025

BugWPB-14874 [Android] White screen after putting wire to background and opening other applications on older devices

https://wearezeta.atlassian.net/browse/WPB-14874

What's new in this PR?

Issues

Issue described in the ticket is caused by slow cold start.

Causes (Optional)

The application start time issue needs more investigation. This PR fixes one issue with the lazy initialization of the CoreLogic.

Solutions

Use Lazy for deferred initialization of CoreLogic. This decreased the cold start time on my Samsung A22 by ~1 second and fixed one StrictMode warning for IO operation on main thread during app start.

Copy link

Copy link

codecov bot commented May 27, 2025

Codecov Report

Attention: Patch coverage is 85.71429% with 10 lines in your changes missing coverage. Please review.

Project coverage is 45.90%. Comparing base (7a2d56d) to head (18dbd7c).

Files with missing lines Patch % Lines
...otlin/com/wire/android/ui/WireActivityViewModel.kt 50.00% 4 Missing ⚠️
...d/ui/home/sync/FeatureFlagNotificationViewModel.kt 86.36% 2 Missing and 1 partial ⚠️
...ialog/deactivated/LegalHoldDeactivatedViewModel.kt 60.00% 1 Missing and 1 partial ⚠️
...otlin/com/wire/android/ui/CallFeedbackViewModel.kt 94.44% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #4041   +/-   ##
========================================
  Coverage    45.90%   45.90%           
========================================
  Files          521      521           
  Lines        18187    18187           
  Branches      3068     3068           
========================================
  Hits          8348     8348           
  Misses        8974     8974           
  Partials       865      865           
Files with missing lines Coverage Δ
...re/android/ui/analytics/AnalyticsUsageViewModel.kt 93.10% <100.00%> (ø)
...wire/android/ui/home/drawer/HomeDrawerViewModel.kt 100.00% <100.00%> (ø)
...ld/dialog/requested/LegalHoldRequestedViewModel.kt 88.63% <100.00%> (ø)
...otlin/com/wire/android/ui/CallFeedbackViewModel.kt 87.83% <94.44%> (ø)
...ialog/deactivated/LegalHoldDeactivatedViewModel.kt 81.57% <60.00%> (ø)
...d/ui/home/sync/FeatureFlagNotificationViewModel.kt 56.57% <86.36%> (ø)
...otlin/com/wire/android/ui/WireActivityViewModel.kt 75.76% <50.00%> (ø)

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 7a2d56d...18dbd7c. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant