Karumi / Dexter

Android library that simplifies the process of requesting permissions at runtime.
http://karumi.com
Apache License 2.0
5.23k stars 671 forks source link

error in build.gradle #180

Closed salmansidd17 closed 3 years ago

salmansidd17 commented 7 years ago

Expected behavior

it was supposed to be successfully compiled when it put compile 'com.karumi:dexter:4.1.0' in the dependencies.

Actual behavior

i am using 'com.android.support:appcompat-v7:25.3.1' and dexter:4.1.0 seems to be incompatible with gradle 25.3.1.

Steps to reproduce

use library with these versions

compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.karumi:dexter:4.1.0'

Version of the library

dexter:4.1.0

Serchinastico commented 6 years ago

Hi @salmansidd17

We have a pending release (will be 4.2.0) that is using com.android.support:appcompat-v7:25.3.1. However, if you need it right now, I'd suggest you to exclude the appcompat dependency from dexter by using this configuration:

compile 'com.karumi:dexter:4.1.0' {
    exclude group: 'com.android.support', module: 'appcompat-v7'
}

I haven't tested it myself but it should work just fine.

salmansidd17 commented 6 years ago

Hi @Serchinastico , I got it to work by downloading the library myself and recompiling it with the latest appcompact version. I'll try your method too. Hope it'll work fine. Thank you :)

yussefbens commented 6 years ago

for those who still researching for solutions with this issue.. try to implement android.design implementation 'com.android.support:design:27.1.1' I tried the solution suggested by @Serchinastico by it not seems working then I download the lib and install it manually in my project and I found the error in the Snackbar where you should already have android.support.design to use it.

leigo commented 5 years ago

compile('com.karumi:dexter:5.0.0') { exclude group: 'com.android.support' }

josephsarz commented 3 years ago

compile('com.karumi:dexter:5.0.0') { exclude group: 'com.android.support' }

This solved my issue. Thanks @leigo