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

Can't disable R8 in newer gradle version #33

Open
theGBguy opened this issue Mar 16, 2023 · 0 comments
Open

Can't disable R8 in newer gradle version #33

theGBguy opened this issue Mar 16, 2023 · 0 comments

Comments

@theGBguy
Copy link

We can't disable R8 in gradle version newer than 7.0. So, it is causing conflict with other dependencies because some of them also have obfuscated a.a(a.b / whatever) class which this library also has. The build logs is as ### follows:

Duplicate class a.a found in modules jetified-eSewaSdk-runtime (eSewaSdk.aar) and jetified-khalti-android-2.01.02-runtime (com.khalti:khalti-android:2.01.02)
Duplicate class b.a found in modules jetified-eSewaSdk-runtime (eSewaSdk.aar) and jetified-khalti-android-2.01.02-runtime (com.khalti:khalti-android:2.01.02)
Duplicate class b.b found in modules jetified-eSewaSdk-runtime (eSewaSdk.aar) and jetified-khalti-android-2.01.02-runtime (com.khalti:khalti-android:2.01.02)
Duplicate class b.c found in modules jetified-eSewaSdk-runtime (eSewaSdk.aar) and jetified-khalti-android-2.01.02-runtime (com.khalti:khalti-android:2.01.02)
Duplicate class c.a found in modules jetified-eSewaSdk-runtime (eSewaSdk.aar) and jetified-khalti-android-2.01.02-runtime (com.khalti:khalti-android:2.01.02)

Solution: as discussed here, please use flattenpackagehierarchy in your ProGuard rules to move obfuscated classes in some unique package to prevent aforementioned conflicts with other libraries.

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

No branches or pull requests

1 participant