breezmobile icon indicating copy to clipboard operation
breezmobile copied to clipboard

Remove android.enableJetifier line from gradle.properties

Open emanuelb opened this issue 1 year ago • 2 comments

https://github.com/breez/breezmobile/blob/632068995018566f57ad2bccd2c1568e6605bb0f/android/gradle.properties#L1

See this guide for the steps to ensure it's safe to remove above line android.enableJetifier=true (check that all deps are already fully migrated to AndroidX, and migrate the ones still not migrated to it) https://medium.com/dipien/say-bye-bye-to-android-jetifier-a7e0d388f5d6

Compiling app result in warning:

WARNING: [Processor] Library '/home/appuser/.gradle/caches/modules-2/files-2.1/androidx.media2/media2-session/1.2.0/e110e7db678fbfc107af48fe6110e3cc713f4564/media2-session-1.2.0.aar' contains references to both AndroidX and old support library. This seems like the library is partially migrated. Jetifier will try to rewrite the library anyway.

emanuelb avatar Aug 07 '22 12:08 emanuelb

@ademar111190 please take a look

kingonly avatar Aug 07 '22 14:08 kingonly

Really interesting gradle plugin, I didn't know about it, thank you for sharing.

Sharing my discoveries, we have two third-party libraries that still use legacy android libraries (scan and urlauncher). Considering the pros and cons I believe it is better to keep the jetifier and wait for these libraries to update so we can remove it safely in the future.

The build time of Breez is not an issue IMHO and even if it was an issue, most of the compile time is on the dart side, the native android side is almost irrelevant.

In summary, I believe we can wait and afford these extra (milli)seconds for now.

ademar111190 avatar Aug 08 '22 14:08 ademar111190