flipper icon indicating copy to clipboard operation
flipper copied to clipboard

Support library classes are packaged into AAR

Open muthuraj57 opened this issue 8 years ago • 6 comments

screen shot 2018-06-12 at 11 46 55 am

Support library classes are packaged with aar instead of resolving it dynamically. And the included support library version is 26.x.x and I'm using 28.0.0-alpha3. There are some breaking changes in 26 to 27 and I can't build my app because of that.

Ex: For fragments, requireContext method is added in 27 and above which is not available in 26 versions.

Due to some reasons, all my support library method calls points to the bundled version of sonar instead of actual library. Please remove the bundled version so that user can customize the version that suits them.

muthuraj57 avatar Jun 12 '18 06:06 muthuraj57

You can implement sonar like this until they fix it.

debugImplementation ('com.facebook.sonar:sonar:0.0.1'){ exclude group: 'android' exclude group: 'javax' exclude group: 'jsr-305' exclude group: 'okhttp3' exclude group: 'okio' exclude group: 'org' exclude group: 'com.google' }

TurKorsaN avatar Jun 12 '18 07:06 TurKorsaN

Just hit this for okhttp

yschimke avatar Jun 12 '18 08:06 yschimke

@TurKorsaN that doesn't fix it for me since they are baked into the Sonar classes.jar file.

$ jar xf sonar-0.0.1.aar classes.jar
$ jar tf classes.jar okhttp3/OkHttpClient.class
okhttp3/OkHttpClient.class

yschimke avatar Jun 12 '18 08:06 yschimke

I think until there's a slim AAR, you would have to use jarjar to remove the bundled dependencies.

passy avatar Jun 12 '18 09:06 passy

See #24 for a related issue and a temporary hack to fix it (until the packaging problems have been solved).

friederbluemle avatar Jun 13 '18 03:06 friederbluemle

Closing in favor of #24

xiphirx avatar Jun 21 '18 08:06 xiphirx