sbis04 / video_trimmer

Flutter video trimmer package
https://pub.dev/packages/video_trimmer
MIT License
440 stars 271 forks source link

Execution failed for task ':app:checkDebugDuplicateClasses'. #158

Closed dannycortesv closed 2 years ago

dannycortesv commented 2 years ago

Hi i'm using also ffmpeg_kit_flutter_full_gpl: ^4.5.1-LTS this cause duplicate classes failure. How can we change the package of ffmpeg plugins?

What went wrong: Execution failed for task ':app:checkReleaseDuplicateClasses'. A failure occurred while executing com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable Duplicate class com.arthenica.ffmpegkit.Abi found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.AbiDetect found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.AbstractSession found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.AsyncFFmpegExecuteTask found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.AsyncFFprobeExecuteTask found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.AsyncGetMediaInformationTask found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.BuildConfig found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.CameraSupport found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Chapter found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegKit found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegKitConfig found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegKitConfig$1 found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegKitConfig$2 found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegKitConfig$SAFProtocolUrl found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegSession found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFmpegSessionCompleteCallback found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFprobeKit found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFprobeSession found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.FFprobeSessionCompleteCallback found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Level found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Log found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.LogCallback found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.LogRedirectionStrategy found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.MediaInformation found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.MediaInformationJsonParser found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.MediaInformationSession found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.MediaInformationSessionCompleteCallback found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.NativeLoader found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Packages found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.ReturnCode found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Session found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.SessionState found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Signal found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.Statistics found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.StatisticsCallback found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS) Duplicate class com.arthenica.ffmpegkit.StreamInformation found in modules jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-full-gpl:4.5.1-1) and jetified-ffmpeg-kit-https-4.5.1-1-runtime (com.arthenica:ffmpeg-kit-https:4.5.1-1.LTS)

felipeemidio commented 2 years ago

Any update?

dannycortesv commented 2 years ago

@felipeemidio Make sure to use the same ffmpeg package on all puglins you use

wolfwithflames commented 2 years ago

Please help on this facing same issue.

sbis04 commented 2 years ago

In your pubspec.yaml file, are you guys using both the ffmpeg_kit_flutter and the video_trimmer packages together?

felipeemidio commented 2 years ago

Yes, @sbis04. My case is that I want to use the video_trimmer package and the ffmpeg_kit_flutter_https_gpl for video convertion (both on version 4.5.1-LTS).

sbis04 commented 2 years ago

I'm not totally sure how this duplicate class error can be fixed, but this thread may help: https://stackoverflow.com/questions/56029393/why-im-getting-duplicate-class-when-running-my-android-project

sbis04 commented 2 years ago

Closing this issue. Please open a new issue if you want to discuss this further.