Pushwoosh / pushwoosh-appcelerator-titanium

Other
33 stars 16 forks source link

SDK9 issues #77

Closed macasfaj closed 3 years ago

macasfaj commented 3 years ago

5.20.1 version is not working yet.

I have conflicts with ti.webdialog, for example. It fires this:

[ERROR]  [GRADLE]

[ERROR]  [GRADLE] FAILURE: Build failed with an exception.

[ERROR]  [GRADLE]

[ERROR]  [GRADLE] * What went wrong:

[ERROR]  [GRADLE] Execution failed for task ':app:checkDebugDuplicateClasses'.

[ERROR]  [GRADLE] > 1 exception was raised by workers:

[ERROR]  [GRADLE] java.lang.RuntimeException: Duplicate class com.google.common.util.concurrent.ListenableFuture found in modules jetified-listenablefuture-1.0.jar (com.google.guava:listenablefuture:1.0) and jetified-listenablefuture-1.0.jar (listenablefuture-1.0.jar)

[ERROR]  [GRADLE]

[ERROR]  [GRADLE] Go to the documentation to learn how to Fix dependency resolution errors.

[ERROR]  [GRADLE]

[ERROR]  [GRADLE]

[ERROR]  [GRADLE] * Try:

[ERROR]  [GRADLE] Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.


Any help? What about version 6?

Thanks.

wfhm commented 3 years ago

Hi! Try to add the following line to your dependencies section in your build.gradle: implementation 'com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava'.

Be sure to add implementation 'androidx.multidex:multidex:2.0.1' and enable mutliDex in your defaultConfig also if you would run into "Cannot fit requested classes in a single dex file" error.

macasfaj commented 3 years ago

Sorry but... where are these files? Which folder? thanks!

wfhm commented 3 years ago

The dependencies and defaultConfig are declared in build.gradle file of your project, the root is: /your_project_folder/app/build.gradle

wfhm commented 3 years ago

@macasfaj,

It seems that the ti.webdialog module adds the com.google.guava:listenablefuture:1.0 dependency via gradle, and our module adds the same library directly by copying a jar in your project. To resolve this conflict, you should remove one instance from your project. If you have access to build.gradle, you can remove it from there, otherwise, you can delete it from the lib directory from Pushwoosh module. Could you please try it and let us know if either option works for you?

macasfaj commented 3 years ago

Thank you! I'll check this evening and send you the result 👍

macasfaj commented 3 years ago

IT WORKS!!! 🥇 Thanks a lot! @wfhm :)