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

Migrate to coil3 #4347

Open
wants to merge 5 commits into
base: develop
Choose a base branch
from
Open

Migrate to coil3 #4347

wants to merge 5 commits into from

Conversation

bmarty
Copy link
Member

@bmarty bmarty commented Mar 3, 2025

Content

Migrate from coil2 to coil3

Ref: https://coil-kt.github.io/coil/upgrading_to_coil3/

Motivation and context

Use up to date dependencies.

Screenshots / GIFs

Tests

  • Check that images (avatar, media in rooms, etc.) are correctly loaded
  • Signout and signin using another account. Images should be loaded correctly.

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

  • Changes have been tested on an Android device or Android emulator with API 24
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly define what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • You've made a self review of your PR

@bmarty bmarty added the PR-Dependencies Pull requests that update a dependency file label Mar 3, 2025
@bmarty bmarty requested a review from a team as a code owner March 3, 2025 11:31
@bmarty bmarty requested review from ganfra and removed request for a team March 3, 2025 11:31
add(
OkHttpNetworkFetcherFactory(
callFactory = {
okHttpClient.get()
Copy link
Member Author

Choose a reason for hiding this comment

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

This does not seem to be used, not sure what's happening here.

Copy link
Member

Choose a reason for hiding this comment

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

What is not used exactly?

Copy link
Member Author

Choose a reason for hiding this comment

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

I set a breakpoint on okHttpClient.get() and starts the application in debug mode (from AS). Images are loaded but the code never breaks.

Copy link
Member

Choose a reason for hiding this comment

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

This sounds wrong then :/
According to the documentation, should be enough

Copy link
Member Author

Choose a reason for hiding this comment

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

I have added logs and confirm that this code is not used. Still digging

Copy link
Contributor

github-actions bot commented Mar 3, 2025

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/tJPwY2

Copy link

codecov bot commented Mar 3, 2025

Codecov Report

Attention: Patch coverage is 31.25000% with 33 lines in your changes missing coverage. Please review.

Project coverage is 80.17%. Comparing base (491bb1d) to head (299f2fb).

Files with missing lines Patch % Lines
...roid/libraries/matrix/ui/media/CoilMediaFetcher.kt 0.00% 13 Missing ⚠️
.../libraries/matrix/ui/media/ImageLoaderFactories.kt 0.00% 11 Missing ⚠️
...android/libraries/designsystem/components/Bloom.kt 0.00% 5 Missing ⚠️
...ent/android/features/location/api/StaticMapView.kt 75.00% 0 Missing and 2 partials ⚠️
...l/notifications/DefaultNotificationBitmapLoader.kt 0.00% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #4347      +/-   ##
===========================================
- Coverage    80.18%   80.17%   -0.02%     
===========================================
  Files         2058     2058              
  Lines        54802    54815      +13     
  Branches      6706     6706              
===========================================
+ Hits         43945    43949       +4     
- Misses        8561     8570       +9     
  Partials      2296     2296              

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

Copy link

sonarqubecloud bot commented Mar 3, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-Dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants