error when adding library to build.gradle
this is my build.gradle
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
android {
compileSdkVersion 28
defaultConfig {
applicationId "io.svzone.sezon"
minSdkVersion 15
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
applicationIdSuffix ".debug"
versionNameSuffix "-debug"
}
/*applicationId = "com.vogella.android.gradlebuildflavors.prod"
versionName = "1.0-paid"*/
}
}
ext {
support_version = '28.0.0'
anko_version = '0.10.4'
retrofit_version = "2.5.0"
firebase_version = '16.0.3'
daggerVersion = "2.16"
anko_version = '0.10.8'
coroutineVersion = "1.0.1"
lifecycle_version = "1.1.1"
}
dependencies {
def excludeSupport26 = {
force = true
exclude group: 'com.android.support', module: 'support-media-compat'
exclude group: 'com.android.support', module: 'support-v4'
// exclude group: 'com.google.android.gms', module: 'play-services-auth'
}
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation "com.android.support:appcompat-v7:$support_version"
implementation "com.android.support:design:$support_version"
// implementation "com.android.support:support-fragment:$support_version"
implementation 'com.android.support.constraint:constraint-layout:2.0.0-alpha2'
//implementation group: 'com.android.support', name: 'support-v4', version: '28.0.0'
// implementation 'com.android.support:support-v4:28.0.0'
// implementation 'com.android.support:support-v4:28.0.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
// Retrofit & OkHttp
implementation "com.squareup.retrofit2:retrofit:$retrofit_version"
implementation "com.squareup.retrofit2:converter-gson:$retrofit_version"
implementation 'com.squareup.okhttp3:okhttp:3.12.0'
implementation 'com.squareup.okhttp3:logging-interceptor:3.11.0'
implementation 'com.jakewharton.retrofit:retrofit2-kotlin-coroutines-experimental-adapter:1.0.0'
// implementation 'com.flipboard:bottomsheet-core:1.5.3'
// implementation 'com.flipboard:bottomsheet-commons:1.5.3' // optional
// implementation 'com.squareup.picasso:picasso:2.71828'
// implementation 'swarajsaaj:otpreader:1.1'
// ImageView Library
implementation 'de.hdodenhof:circleimageview:2.2.0'
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutineVersion"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutineVersion"
implementation 'com.facebook.android:account-kit-sdk:4.+'
implementation 'com.romandanylyk:pageindicatorview:1.0.2'
implementation "com.android.support:recyclerview-v7:$support_version"
implementation 'com.google.android.gms:play-services-auth:16.0.1'
implementation 'com.google.android.gms:play-services-maps:16.0.0', excludeSupport26
// ViewModel and LiveData
implementation("android.arch.lifecycle:extensions:$lifecycle_version") {
exclude group: "com.android.support", module: "support-fragment"
}
// // Koin for Android
// implementation('org.koin:koin-android:1.0.2')
// // or Koin for Lifecycle scoping
// /* implementation('org.koin:koin-android-scope:1.0.2') {
// exclude group: 'com.android.support', module: 'support-v4'
// exclude group: "com.android.support", module: "support-fragment"
// }*/
// // or Koin for Android Architecture ViewModel
// implementation('org.koin:koin-android-viewmodel:1.0.2')
}
it gives me lib conflict i resolve
Failed to resolve: support-fragment
Open File
but i can't download support fragment and support v4
i try a lot of times and it give me please install android support library but its already installed
what i should do ?
see the attachment
You need to add the support library com.android.support:support-fragment:28.0.0
Try to install from. You can give it a try to install it from this path:
Android Studio, go in the menu File > Project Structure (Ctrl + Alt + Shift + S)
Select app, tab Dependencies and there search for com.android.support:support-fragment:28.0.0
If this is not working try this :
allprojects {
repositories {
maven {
url "https://maven.google.com"
}
}
}
Let me know if this works.
Related
I was using Glide for images and it was working fine till now. But now when I integrate Realm database in my project it is giving error for generating GlideApp & GlideRequests classes.
Main build.gradle
buildscript {
repositories {
mavenCentral()
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.1'
classpath 'io.realm:realm-gradle-plugin:5.8.0'
}
}
allprojects {
repositories {
mavenCentral()
google()
jcenter()
maven {
url "https://raw.github.com/signalapp/maven/master/photoview/releases/"
}
maven {
url "https://raw.github.com/signalapp/maven/master/circular-progress-button/releases/"
}
maven {
url "https://raw.github.com/signalapp/maven/master/sqlcipher/release/"
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
App build.gradle
apply plugin: 'com.android.application'
apply plugin: 'realm-android'
android {
flavorDimensions "none"
compileSdkVersion 28
buildToolsVersion '28.0.3'
useLibrary 'org.apache.http.legacy'
defaultConfig {
applicationId "com.deskera.desk"
minSdkVersion 19
targetSdkVersion 28
versionCode 1
versionName "1.0"
vectorDrawables.useSupportLibrary = true
multiDexEnabled true
vectorDrawables.useSupportLibrary = true
project.ext.set("archivesBaseName", "DESK")
ndk { abiFilters "armeabi", "armeabi-v7a", "x86", "mips" }
}
buildTypes {
debug {
minifyEnabled true
useProguard true
proguardFiles getDefaultProguardFile('proguard-android.txt'),
'proguard-glide.pro',
'proguard.cfg'
}
release {
minifyEnabled true
proguardFiles = buildTypes.debug.proguardFiles
}
}
dexOptions {
javaMaxHeapSize "4g"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
packagingOptions {
exclude 'LICENSE.txt'
exclude 'LICENSE'
exclude 'NOTICE'
exclude 'asm-license.txt'
exclude 'META-INF/LICENSE'
exclude 'META-INF/NOTICE'
exclude 'META-INF/proguard/androidx-annotations.pro'
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'
def supportVersion = '28.0.0'
implementation "com.android.support:appcompat-v7:$supportVersion"
implementation "com.android.support:recyclerview-v7:$supportVersion"
implementation "com.android.support:design:$supportVersion"
implementation "com.android.support:support-v13:$supportVersion"
implementation "com.android.support:cardview-v7:$supportVersion"
implementation "com.android.support:preference-v7:$supportVersion"
implementation "com.android.support:preference-v14:$supportVersion"
implementation "com.android.support:gridlayout-v7:$supportVersion"
implementation "com.android.support:exifinterface:$supportVersion"
implementation 'com.android.support:multidex:1.0.3'
implementation 'android.arch.lifecycle:extensions:1.1.1'
implementation 'android.arch.lifecycle:common-java8:1.1.1'
implementation 'android.arch.work:work-runtime:1.0.0-alpha11'
implementation 'com.google.android.gms:play-services-gcm:9.6.1'
implementation 'com.google.android.gms:play-services-maps:9.6.1'
implementation 'com.google.android.gms:play-services-places:9.6.1'
implementation 'com.google.android.exoplayer:exoplayer-core:2.9.1'
implementation 'com.google.android.exoplayer:exoplayer-ui:2.9.1'
implementation 'org.whispersystems:signal-service-android:2.12.2'
implementation 'org.whispersystems:webrtc-android:M69'
implementation "me.leolin:ShortcutBadger:1.1.16"
implementation 'se.emilsjolander:stickylistheaders:2.7.0'
implementation 'com.jpardogo.materialtabstrip:library:1.0.9'
implementation 'org.apache.httpcomponents:httpclient-android:4.3.5'
implementation 'com.github.chrisbanes:PhotoView:2.1.3'
implementation 'com.github.bumptech.glide:glide:4.8.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.8.0'
implementation 'com.makeramen:roundedimageview:2.1.0'
implementation 'com.pnikosis:materialish-progress:1.5'
implementation 'org.greenrobot:eventbus:3.0.0'
implementation 'pl.tajchert:waitingdots:0.1.0'
implementation 'com.soundcloud.android:android-crop:0.9.10#aar'
implementation 'com.melnykov:floatingactionbutton:1.3.0'
implementation 'com.google.zxing:android-integration:3.1.0'
implementation 'com.squareup.dagger:dagger:1.2.2'
annotationProcessor 'com.squareup.dagger:dagger-compiler:1.2.2'
implementation 'mobi.upod:time-duration-picker:1.1.3'
compileOnly 'com.squareup.dagger:dagger-compiler:1.2.2'
implementation 'com.amulyakhare:com.amulyakhare.textdrawable:1.0.1'
implementation 'com.google.zxing:core:3.2.1'
implementation('com.davemorrissey.labs:subsampling-scale-image-view:3.6.0') {
exclude group: 'com.android.support', module: 'support-annotations'
}
implementation('cn.carbswang.android:NumberPickerView:1.0.9') {
exclude group: 'com.android.support', module: 'appcompat-v7'
}
implementation('com.tomergoldst.android:tooltips:1.0.6') {
exclude group: 'com.android.support', module: 'appcompat-v7'
}
implementation('com.klinkerapps:android-smsmms:4.0.1') {
exclude group: 'com.squareup.okhttp', module: 'okhttp'
exclude group: 'com.squareup.okhttp', module: 'okhttp-urlconnection'
}
implementation 'com.annimon:stream:1.1.8'
implementation('com.takisoft.fix:colorpicker:0.9.1') {
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'com.android.support', module: 'recyclerview-v7'
}
implementation 'com.codewaves.stickyheadergrid:stickyheadergrid:0.9.4'
implementation 'com.github.dmytrodanylyk.circular-progress-button:library:1.1.3-S2'
implementation 'org.signal:android-database-sqlcipher:3.5.9-S3'
implementation('com.googlecode.ez-vcard:ez-vcard:0.9.11') {
exclude group: 'com.fasterxml.jackson.core'
exclude group: 'org.freemarker'
}
}
When I only ingrate Realm in build.gradle it doesn't show any error. But when I add RealmObjects or create class using RealmObject, it gives following errors
error: cannot find symbol class GlideApp
error: cannot find symbol class GlideRequests
error: cannot find symbol class GlideRequest
error: cannot find symbol class GlideRequests
where V is a type-variable:
V extends View,BindableConversationItem declared in class ConversationAdapter
As soon as I add latest version of firebase-perf library it stops compiling with the following error:
Caused by: com.android.tools.r8.utils.AbortException:
Error: Program type already present: com.google.android.gms.internal.measurement.zzu
Note: I am already using latest version of all the available dependencies from android and Firebase.
My project level build.gradle:
buildscript {
repositories {
google()
jcenter()
maven { url 'https://maven.fabric.io/public' }
maven {
url 'https://maven.google.com/'
name 'Google'
}
}
dependencies {
classpath 'com.android.tools.build:gradle:3.2.1'
classpath 'io.fabric.tools:gradle:1.+'
classpath 'com.google.gms:google-services:4.2.0'
classpath 'com.google.firebase:firebase-plugins:1.1.5'
}
}
allprojects {
repositories {
google()
jcenter()
mavenCentral()
maven { url 'https://maven.fabric.io/public' }
maven { url 'http://dl.bintray.com/amulyakhare/maven' }
maven { url "https://jitpack.io" }
maven {
url 'https://github.com/WickeDev/stetho-realm/raw/master/maven-repo'
}
}
}
My app level build.gradle:
apply plugin: 'com.android.application'
apply plugin: 'com.google.firebase.firebase-perf'
apply plugin: 'io.fabric'
apply plugin: 'realm-android'
task wrapper(type: Wrapper) {
gradleVersion = '4.1'
}
buildscript {
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath "io.realm:realm-gradle-plugin:5.4.1"
}
}
subprojects {
project.configurations.all {
resolutionStrategy.eachDependency { details ->
if (details.requested.group == 'com.android.support'
&& !details.requested.name.contains('multidex')) {
details.useVersion "26.1.0"
}
}
}
}
android {
compileSdkVersion 28
buildToolsVersion '28.0.3'
configurations.all {
resolutionStrategy.force 'com.google.code.findbugs:jsr305:1.3.9'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
defaultConfig {
minSdkVersion 15
targetSdkVersion 28
versionCode 180
versionName "2.11.8"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
resConfigs "en"
}
dexOptions {
javaMaxHeapSize "4G"
maxProcessCount 4
}
buildTypes {
debug {
minifyEnabled false
}
release {
minifyEnabled true
shrinkResources true
proguardFile getDefaultProguardFile('proguard-android.txt')
fileTree(dir: 'proguard-rules', include: '*.pro').each { file -> proguardFile file }
}
}
aaptOptions {
cruncherEnabled false
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/services/javax.annotation.processing.Processor'
exclude 'META-INF/ECLIPSE_.SF'
exclude 'META-INF/ECLIPSE_.RSA'
}
}
dependencies {
// https://mvnrepository.com/artifact/commons-codec/commons-codec
implementation group: 'commons-codec', name: 'commons-codec', version: '1.10'
// Support library
implementation('com.android.support:appcompat-v7:28.0.0') {
exclude group: 'com.android.support', module: 'support-annotations'
}
// Play services
implementation('com.google.android.gms:play-services-analytics:15.0.2') {
exclude group: 'com.android.support'
// exclude group: 'com.google.android.gms', module: 'play-services-basement'
// exclude group: 'com.google.android.gms', module: 'play-services-measurement-base'
}
implementation 'com.google.android.gms:play-services-auth:16.0.1';
// Square
implementation("com.squareup.okhttp3:okhttp:3.12.0")
implementation('com.squareup.okhttp3:logging-interceptor:3.12.0') {
transitive = false
}
implementation('com.squareup.retrofit2:retrofit:2.5.0') {
// exclude Retrofit’s OkHttp peer-dependency module and define your own module import
exclude module: 'okhttp'
}
implementation 'com.squareup.retrofit2:adapter-rxjava:2.5.0'
implementation 'com.squareup.retrofit2:converter-gson:2.5.0'
// UI/UX
implementation('com.kogitune:pre-lollipop-activity-transition:1.3.0') {
exclude group: 'com.android.support'
}
//App Intro
implementation('com.github.paolorotolo:appintro:4.1.0#aar') {
exclude group: 'com.android.support'
transitive = true
}
// Tools
implementation('io.branch.sdk.android:library:2.+') {
exclude group: 'com.android.support'
}
implementation('com.crashlytics.sdk.android:crashlytics:2.5.2#aar') {
transitive = true
}
// Test
androidTestImplementation('com.android.support.test.espresso:espresso-contrib:2.2') {
// Necessary to avoid version conflicts
exclude module: 'recyclerview-v7'
}
// Razorpay
implementation 'com.razorpay:checkout:1.5.1'
//Reactive Location
implementation 'pl.charmas.android:android-reactive-location:1.0#aar'
implementation 'com.android.support:multidex:1.0.3'
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support:animated-vector-drawable:28.0.0'
implementation 'com.android.support:customtabs:28.0.0'
implementation 'com.android.support:exifinterface:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:support-media-compat:28.0.0'
implementation 'com.android.support:cardview-v7:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation 'com.android.support:support-annotations:28.0.0'
implementation 'com.google.android.gms:play-services-location:16.0.0'
implementation 'com.google.android.gms:play-services-maps:16.0.0'
implementation 'com.google.android.libraries.places:places-compat:1.0.0'
implementation 'com.squareup.okio:okio:1.15.0'
implementation 'com.google.code.gson:gson:2.8.5'
dependencies {
implementation 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'
}
implementation 'com.jakewharton.timber:timber:4.1.2'
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.jakewharton.picasso:picasso2-okhttp3-downloader:1.1.0'
implementation 'com.balysv:material-ripple:1.0.2'
implementation 'com.amulyakhare:com.amulyakhare.textdrawable:1.0.1'
implementation 'com.timehop.stickyheadersrecyclerview:library:0.4.3#aar'
implementation 'me.zhanghai.android.materialprogressbar:library:1.1.4#aar'
implementation 'com.wdullaer:materialdatetimepicker:2.3.0#aar'
implementation 'com.orhanobut:logger:1.8'
implementation 'com.facebook.conceal:conceal:1.0.1#aar'
implementation 'io.reactivex:rxjava:1.3.0'
implementation 'io.reactivex:rxandroid:1.2.1#aar'
implementation 'com.f2prateek.rx.preferences:rx-preferences:1.0.2#aar'
implementation 'com.tbruyelle.rxpermissions:rxpermissions:0.9.4#aar'
dependencies {
implementation 'com.google.dagger:dagger:2.13'
annotationProcessor 'com.google.dagger:dagger-compiler:2.13'
}
dependencies {
implementation 'com.github.matthiasrobbers:shortbread:1.0.2'
annotationProcessor 'com.github.matthiasrobbers:shortbread-compiler:1.0.2'
}
implementation 'org.jbundle.util.osgi.wrapped:org.jbundle.util.osgi.wrapped.org.apache.http.client:4.1.2'
implementation 'com.google.firebase:firebase-messaging:17.3.4'
implementation 'com.google.firebase:firebase-core:16.0.6'
implementation('com.google.firebase:firebase-perf:16.2.3') <------------- Compile issue happens when I add this
implementation 'com.facebook.stetho:stetho:1.5.0'
implementation 'com.facebook.stetho:stetho-okhttp3:1.5.0'
// implementation 'com.uphyca:stetho_realm:2.3.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'org.robolectric:robolectric:3.0'
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:1.10.19'
androidTestImplementation 'com.jakewharton:butterknife:8.8.1'
androidTestImplementation 'com.android.support:support-annotations:28.0.0'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test:rules:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-intents:3.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-idling-resource:3.0.2'
androidTestImplementation 'com.android.support.test.uiautomator:uiautomator-v18:2.1.3'
androidTestImplementation 'com.android.support:support-v4:28.0.0'
implementation 'com.elyeproj.libraries:loaderviewlibrary:1.4.1'
// Animations
implementation 'com.android.support:support-compat:28.0.0'
implementation 'com.daimajia.easing:library:2.0#aar'
implementation 'com.daimajia.androidanimations:library:2.3#aar'
// Pusher
implementation 'com.pusher:pusher-java-client:1.6.0'
// Custom crash activity
implementation 'cat.ereza:customactivityoncrash:2.2.0'
// Snackbar
implementation 'com.github.matecode:Snacky:1.0.3'
// Progress bar
implementation 'com.github.castorflex.smoothprogressbar:library:1.3.0'
implementation 'com.github.chrisbanes:PhotoView:2.0.0'
// debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.6.2'
// releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.6.2'
implementation 'org.conscrypt:conscrypt-android:1.4.1'
// Facebook connection class to classify network bandwidth
implementation 'com.facebook.network.connectionclass:connectionclass:1.0.1';
}
apply from: 'tasks.gradle'
apply plugin: 'com.google.gms.google-services'
com.google.gms.googleservices.GoogleServicesPlugin.config.disableVersionCheck = true
I solved this problem by removing play-services-analytics from the app level build.gradle.
implementation('com.google.android.gms:play-services-analytics:15.0.2') {
exclude group: 'com.android.support'
}
It seems like firebase analytics and google analytics can't coexist.
Am getting this warning during my build .
Warning: Exception while processing task java.io.IOException: Can't
write
[/Users/petrose/as_projects/MrPhone/app/build/intermediates/transforms/proguard/debug/0.jar]
(Can't read
[/Users/petrose/.gradle/caches/transforms-1/files-1.1/firebase-analytics-impl-16.2.4.aar/288ad7982e8f6024c8b5f0954f183721/jars/classes.jar(;;;;;;;**.class)]
(Duplicate jar entry
[com/google/android/gms/internal/measurement/eo.class]))
apply plugin: 'com.android.application'
//apply plugin: 'com.google.firebase.firebase-perf'
apply plugin: 'org.greenrobot.greendao'
//apply plugin: 'io.fabric'
android {
compileSdkVersion rootProject.ext.compileSdkVersion
defaultConfig {
applicationId "....."
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 1
versionName "1.0.1"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
vectorDrawables { useSupportLibrary = true }
multiDexEnabled true
resConfigs "en"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
buildTypes {
release {
minifyEnabled true
useProguard true // obfuscate
shrinkResources true
}
debug {
minifyEnabled true
useProguard true // obfuscate
shrinkResources false
}
}
packagingOptions {
exclude 'META-INF/rxjava.properties'
}
}
greendao {
schemaVersion 1
}
dependencies {
//extLib
implementation files('libs/YouTubeAndroidPlayerApi.jar')
//support Lib
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation "com.android.support:appcompat-v7:28.0.0"
implementation "com.android.support:recyclerview-v7:28.0.0"
implementation "com.android.support:cardview-v7:28.0.0"
implementation "com.android.support:design:28.0.0"
implementation "com.android.support:support-vector-drawable:28.0.0"
implementation "com.android.support.constraint:constraint-layout:$rootProject.constraintLibraryVersion"
implementation "com.android.support:customtabs:28.0.0"
//Google API Client Library
implementation('com.google.apis:google-api-services-youtube:v3-rev195-1.23.0') {
exclude group: 'org.apache.httpcomponents', module: 'httpclient'
exclude group: 'com.google.guava'
}
implementation('com.google.api-client:google-api-client-android:1.23.0') {
exclude group: 'org.apache.httpcomponents'
exclude group: 'com.google.guava'
}
// implementation('com.google.apis:google-api-services-calendar:v3-rev309-1.23.0') {
// exclude group: 'org.apache.httpcomponents'
// exclude group: 'com.google.guava'
//
// }
// image
//implementation "com.github.bumptech.glide:glide:$rootProject.glideVersion"
// implementation 'com.android.support:support-v4:27.1.1'
// implementation 'com.android.support.constraint:constraint-layout:1.1.0'
//annotationProcessor "com.github.bumptech.glide:compiler:$rootProject.glideVersion"
implementation "com.squareup.picasso:picasso:$rootProject.picassoVersion"
implementation 'com.jakewharton.picasso:picasso2-okhttp3-downloader:1.0.2'
implementation 'com.commit451:PhotoView:1.2.4'
//Network
implementation 'com.squareup.okhttp3:logging-interceptor:3.10.0'
implementation "com.squareup.retrofit2:retrofit:$rootProject.retorfitVersion"
implementation 'com.squareup.retrofit2:converter-scalars:2.2.0'
implementation "com.squareup.retrofit2:converter-gson:$rootProject.retorfitVersion"
implementation "com.squareup.retrofit2:adapter-rxjava2:$rootProject.retorfitVersion"
implementation 'org.jsoup:jsoup:1.10.3'
// parser
implementation "com.google.code.gson:gson:$rootProject.gsonVersion"
implementation 'com.fatboyindustrial.gson-jodatime-serialisers:gson-jodatime-serialisers:1.6.0'
//parceler
implementation 'org.parceler:parceler-api:1.1.12'
annotationProcessor 'org.parceler:parceler:1.1.12'
// database
implementation "org.greenrobot:greendao:$rootProject.greenDaoVersion"
debugImplementation "com.amitshekhar.android:debug-db:$rootProject.debugDBVersion"
//eventBus
implementation "org.greenrobot:eventbus:$rootProject.greenrobotVersion"
//DI
implementation "com.google.dagger:dagger-android:$rootProject.dagger2Version"
annotationProcessor "com.google.dagger:dagger-compiler:$rootProject.dagger2Version"
implementation 'javax.inject:javax.inject:1'
compileOnly 'javax.annotation:jsr250-api:1.0'
// reactive
implementation "io.reactivex.rxjava2:rxjava:$rootProject.rxjava2Version"
implementation "com.github.miguelbcr:RxPaparazzo:$rootProject.rxRxPaparazzo"
implementation 'com.jakewharton.rxbinding2:rxbinding-appcompat-v7:2.1.1'
implementation "com.github.akarnokd:rxjava2-extensions:0.18.7"
//butterknife
implementation "com.jakewharton:butterknife:$rootProject.butterKnifeVersion"
annotationProcessor "com.jakewharton:butterknife-compiler:$rootProject.butterKnifeVersion"
// logger
implementation "com.jakewharton.timber:timber:$rootProject.timberVersion"
implementation "com.github.nisrulz:easydeviceinfo-base:$rootProject.easyDeviceInfoVersion"
implementation 'com.github.tslamic:dn3:3.0'
//Firebase crash analytics
//implementation 'com.crashlytics.sdk.android:crashlytics:2.9.8'
// facebook sdk
// implementation "com.facebook.android:facebook-android-sdk:$rootProject.facebookAndroidSDK"
// implementation "com.facebook.android:audience-network-sdk:$rootProject.facebookNetworkSDK"
implementation 'com.facebook.android:facebook-login:4.28.0'
implementation 'com.facebook.android:audience-network-sdk:5.1.0-beta'
// google sdk
// implementation "com.google.android.gms:play-services-analytics:$rootProject.googleLibraryVersion"
implementation('com.google.android.gms:play-services-analytics:16.0.4') {
exclude group: 'com.google.guava'
}
implementation('com.google.android.gms:play-services-ads:17.0.0') {
exclude group: 'com.google.guava'
}
implementation('com.google.android.gms:play-services-auth:16.0.0') {
exclude group: 'com.google.guava'
}
implementation('com.google.android.gms:play-services-gcm:16.0.0') {
exclude group: 'com.google.guava'
}
// fireBase libraries
implementation 'com.google.firebase:firebase-core:16.0.6'
implementation 'com.google.firebase:firebase-messaging:17.3.4'
implementation 'com.google.firebase:firebase-config:16.1.3'
implementation 'com.google.firebase:firebase-auth:16.1.0'
implementation 'com.google.firebase:firebase-inappmessaging-display:17.0.4'
implementation 'com.google.firebase:firebase-appindexing:17.1.0'
implementation 'com.firebase:firebase-jobdispatcher:0.8.5'
//implementation 'com.google.firebase:firebase-perf:16.2.3'
//implementation 'com.crashlytics.sdk.android:crashlytics:2.9.8'
//leak
//debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.5.4'
//releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.4'
//testLib
//testImplementation 'junit:junit:4.12'
// androidTestImplementation 'com.android.support.test:runner:1.0.1'
// androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
}
apply plugin: 'com.google.gms.google-services'
configurations.all {
resolutionStrategy.eachDependency { DependencyResolveDetails details ->
def requested = details.requested
if (requested.group == 'com.android.support') {
if (!requested.name.startsWith("multidex")) {
details.useVersion '27.1.1'
}
}
}
}
//Top-level build file
buildscript {
repositories {
google()
jcenter()
google()
jcenter()
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.0'
classpath 'com.google.gms:google-services:4.2.0'
classpath 'org.greenrobot:greendao-gradle-plugin:3.2.2'
classpath 'io.fabric.tools:gradle:1.27.0'
classpath 'com.google.firebase:firebase-plugins:1.1.5'
}
}
allprojects {
repositories {
google()
jcenter()
mavenCentral()
maven { url "https://jitpack.io" }
maven { url 'https://maven.google.com' }
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
While preparing for output jar (0.jar) at path {module}/build/intermediates/transforms/proguard/debug/0.jar, gradle copies all dependent library classes.jars and there dependent classes.jar to form a single intermediate jar. So when 2 different libraries are dependent on a single module, that single module is copied twice while leads to this error.
This can be solved by marking compileOnly to that single module in libraries which are using that module.
I cleaned the project and rebuild the project, but I am still getting the error that Error: Program type already present: android.support.compat.R
this is my build.gradle
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
buildscript {
repositories {
jcenter()
mavenCentral()
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.+'
}
}
allprojects {
repositories {
maven { url "https://jitpack.io" }
}
}
android {
compileSdkVersion 27
buildToolsVersion '27.0.3'
lintOptions {
abortOnError false
checkReleaseBuilds false
}
defaultConfig {
applicationId "example.com"
minSdkVersion 21
versionCode 93
versionName "4.1.7"
// 92 416
multiDexEnabled true
}
buildTypes {
release {
// shrinkResources true
// minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.config
}
}
// these are the lines that you have to add
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/notice.txt'
exclude 'META-INF/MANIFEST.MF'
exclude 'META-INF/license.txt'
exclude 'META-INF/dependencies.txt'
}
dataBinding {
enabled true
}
}
repositories {
maven {
url "https://repo.eclipse.org/content/repositories/paho-snapshots/"
}
maven { url 'https://maven.fabric.io/public' }
maven {
url
'https://github.com/suckgamony/RapidDecoder/raw/master/repository'
}
}
dependencies {
// implementation fileTree(include: ['*.jar'], dir: 'libs')
testImplementation 'junit:junit:4.12'
androidTestImplementation('com.android.support.test.espresso:espresso-
core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.android.support:cardview-v7:27.1.1'
implementation 'com.android.support:customtabs:27.1.1'
implementation 'com.nostra13.universalimageloader:universal-image-
loader:1.9.5'
implementation 'com.amazonaws:aws-android-sdk-apigateway-core:2.3.1'
implementation 'com.amazonaws:aws-android-sdk-core:2.3.1'
implementation 'com.amazonaws:aws-android-sdk-s3:2.3.1'
// implementation 'com.google.code.gson:gson:2.7'
// compile files('libs/com.cielowigle-2.4.8.jar')
/* implementation 'com.google.android.gms:play-services-maps:10.2.6'
implementation 'com.google.android.gms:play-services-
location:10.2.6'
implementation 'com.google.android.gms:play-services-plus:10.2.6'
implementation 'com.google.android.gms:play-services-gcm:10.2.6'*/
implementation 'com.google.android.gms:play-services-maps:15.0.1'
implementation 'com.google.android.gms:play-services-location:15.0.1'
implementation 'com.google.android.gms:play-services-plus:15.0.1'
implementation 'com.google.android.gms:play-services-gcm:15.0.1'
implementation 'com.google.android.gms:play-services-auth:15.0.1'
/* compile 'net.zetetic:android-database-sqlcipher:3.5.4#aar'*/
implementation('org.eclipse.paho:org.eclipse.paho.client.mqttv3:1.1.1')
{
exclude group: 'com.android.support', module:'appcompat'
}
implementation('org.eclipse.paho:org.eclipse.paho.android.service:1.1.2-
SNAPSHOT') {
exclude group: 'com.android.support', module:'appcompat'
}
implementation 'com.nineoldandroids:library:2.4.0'
implementation 'com.github.wangjiegulu:AndroidBucket:1.0.4'
implementation 'com.github.wangjiegulu:ShadowViewHelper:1.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
// implementation files('libs/bcpkix-jdk15on-1.52.jar')
// implementation files('libs/bcprov-jdk15on-1.54.jar')
implementation 'com.github.PhilJay:MPAndroidChart:v3.0.1'
implementation 'com.wdullaer:materialdatetimepicker:2.5.0'
implementation 'com.facebook.android:facebook-android-sdk:4.27.0'
implementation 'com.nostra13.universalimageloader:universal-image-
loader:1.9.5'
apply plugin: 'com.google.gms.google-services'
implementation 'com.theartofdev.edmodo:android-image-cropper:2.7.0'
implementation files('libs/Jsonvalidation.jar')
implementation('com.crashlytics.sdk.android:crashlytics:2.6.5#aar') {
transitive = true;
}
implementation 'com.timehop.stickyheadersrecyclerview:library:0.4.1'
implementation 'rapid.decoder:library:0.3.0'
//implementation 'rapid.decoder:jpeg-decoder:0.3.0'
//implementation 'rapid.decoder:png-decoder:0.3.0'
//Retrofit New Libs
implementation 'com.squareup.retrofit2:retrofit:2.4.0'
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
implementation 'com.squareup.retrofit2:converter-scalars:2.3.0'
// Dragger
/* implementation "com.google.dagger:dagger:2.11"
annotationProcessor "com.google.dagger:dagger-compiler:2.11"
// provided 'javax.hj:jsr250-api:1.0'
implementation 'javax.inject:javax.inject:1'*/
implementation 'com.google.dagger:dagger:2.11'
implementation 'com.google.dagger:dagger-android-support:2.11'
annotationProcessor 'com.google.dagger:dagger-compiler:2.11'
annotationProcessor 'com.google.dagger:dagger-android-processor:2.11'
// debug db
debugImplementation 'com.amitshekhar.android:debug-db:1.0.0'
implementation('com.crashlytics.sdk.android:answers:1.4.1#aar') {
transitive = true;
}
}
I tried also invalidate cache option but I am getting the same error. I updated gradle and Google play service latest version. This is working in debug option but not in release mode.
I have a huge project with databinding, kotlin, dagger. I spent a few days trying to build it using several stackoverflow's solutions and decided to ask it personally.
I assume some of third party libraries uses databinding because adding this line doesn't help.
kapt 'com.android.databinding:compiler:3.0.0'
Android Studio says:
'androidProcessor' dependencies won't be recognized as kapt annotation processors. Please change the configuration name to 'kapt' for these artifacts: 'com.android.databinding:compiler:3.0.0'.
What I've tried and it didn't help:
kapt {
generateStubs = true
}
in local.properties: kotlin.incremental=false
another SO solution didn't help:
kapt ('com.android.databinding:compiler:3.0.0'){
force = true
}
my build.gradle
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'blockcanaryex'
apply plugin: 'kotlin-kapt'
apply plugin: 'newrelic'
apply plugin: 'kotlin-android-extensions'
def props = new Properties()
file("newrelic.properties").withInputStream { props.load(it) }
android {
compileSdkVersion 26
buildToolsVersion '26.0.2'
applicationVariants.all { variant ->
variant.outputs.each { output ->
def stdout = new ByteArrayOutputStream()
exec {
commandLine "git", "symbolic-ref", "--short", "HEAD"
standardOutput = stdout
}
def branch = stdout.toString().trim()
branch = "branch.$branch"
if (project.hasProperty("buildNumber")) {
def buildNumber = project.property("buildNumber")
output.outputFile = new File(output.outputFile.parent, output.outputFile.name.replace(".apk", "-" + branch + "-" + versionName + "." + versionCode + "." + buildNumber + ".apk"))
} else {
output.outputFile = new File(output.outputFile.parent, output.outputFile.name.replace(".apk", "-" + branch + "-" + versionName + "." + versionCode + ".apk"))
}
}
}
def version = "4.15"
defaultConfig {
buildConfigField "String", "TOKEN", "\"" + props.getProperty("token") + "\""
applicationId "xxx"
minSdkVersion 19
targetSdkVersion 26
versionName version
versionCode 260
multiDexEnabled true
vectorDrawables.useSupportLibrary = true
}
signingConfigs {
release {
storeFile file("xxx")
storePassword "xxx"
keyAlias "xxx"
keyPassword "xxx"
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
signingConfig signingConfigs.release
}
debug {
versionNameSuffix ".debug"
}
}
flavorDimensions "prod","stag"
productFlavors {
production {
dimension "prod"
}
staging {
dimension "stag"
applicationId "app.id"
versionName(version + ".staging")
}
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/notice.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/dependencies.txt'
exclude '.readme'
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_7
}
dexOptions {
javaMaxHeapSize "4g"
}
dataBinding {
enabled = true
}
}
repositories {
jcenter()
maven { url "https://jitpack.io" }
maven { url 'https://bitbucket.org/gryphteam/maven/raw/release' }
maven {
url 'https://maven.google.com/'
name 'Google'
}
}
def supportVersion = "26.1.0"
def playServicesVersion = "11.6.0"
def retrofitVersion = "2.3.0"
dependencies {
implementation 'com.jakewharton:butterknife:6.1.0'
implementation('de.keyboardsurfer.android.widget:crouton:1.8.5#aar') {
exclude group: 'com.google.android', module: 'support-v4'
}
implementation 'com.google.dagger:dagger:2.10'
kapt 'com.google.dagger:dagger-compiler:2.10'
kapt 'com.android.databinding:compiler:3.0.0'
implementation 'de.greenrobot:eventbus:2.4.0'
implementation 'com.mcxiaoke.volley:library:1.0.19'
implementation 'com.google.code.gson:gson:2.8.0'
implementation "com.google.android.gms:play-services-places:$playServicesVersion"
implementation "com.google.android.gms:play-services-plus:$playServicesVersion"
implementation "com.google.android.gms:play-services-analytics:$playServicesVersion"
implementation "com.google.android.gms:play-services-auth:$playServicesVersion"
implementation "com.google.android.gms:play-services-gcm:$playServicesVersion"
implementation "com.google.android.gms:play-services-ads:$playServicesVersion"
implementation "com.android.support:appcompat-v7:$supportVersion"
implementation "com.android.support:support-v13:$supportVersion"
implementation "com.android.support:recyclerview-v7:$supportVersion"
implementation "com.android.support:design:$supportVersion"
implementation "com.android.support:support-annotations:$supportVersion"
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.android.support:multidex:1.0.2'
implementation 'commons-io:commons-io:2.4'
implementation 'org.apache.commons:commons-lang3:3.1'
implementation files('libs/comscore.jar')
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.github.PhilJay:MPAndroidChart:v3.0.2'
implementation 'com.github.deano2390:MaterialShowcaseView:1.0.5'
implementation 'com.amulyakhare:com.amulyakhare.textdrawable:1.0.1'
implementation 'com.google.ads.mediation:facebook:4.26.1.0'
implementation 'com.facebook.android:audience-network-sdk:4.26.1'
implementation 'org.jboss.netty:netty:3.2.10.Final'
//Testing
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:1.10.19'
androidTestImplementation 'com.android.support:multidex:1.0.2'
androidTestImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test.espresso:espresso-web:3.0.1'
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test:runner:0.3') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test:rules:0.3') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test.espresso:espresso-intents:2.2') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test.espresso:espresso-contrib:2.2') {
exclude group: 'com.android.support', module: 'app-compat'
exclude group: 'com.android.support', module: 'support-v4'
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
exclude module: 'recyclerview-v7'
}
androidTestImplementation 'com.android.support.test.uiautomator:uiautomator-v18:2.1.3'
androidTestImplementation "com.android.support:support-annotations:$supportVersion"
implementation project(':eventsource_android-release')
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
debugImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRT:0.9.5.3'
releaseImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRTNoOp:0.9.5.3'
testImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRTNoOp:0.9.5.3'
implementation 'me.mvdw.recyclerviewmergeadapter:recyclerviewmergeadapter:2.0.0'
debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.5.1'
releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
testImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
implementation "com.squareup.retrofit2:retrofit:$retrofitVersion"
implementation 'com.squareup.okhttp3:logging-interceptor:3.8.0'
implementation "com.squareup.retrofit2:converter-gson:$retrofitVersion"
implementation "com.squareup.retrofit2:adapter-rxjava2:$retrofitVersion"
implementation 'io.reactivex.rxjava2:rxjava:2.1.2'
implementation 'io.reactivex.rxjava2:rxandroid:2.0.1'
implementation 'com.github.ReactiveX:RxKotlin:2.1.0'
implementation 'com.gojuno.koptional:koptional-rxjava2-extensions:1.2.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
implementation 'com.newrelic.agent.android:android-agent:5.14.0'
implementation 'org.jsoup:jsoup:1.10.3'
}
I just tried with similar build.gradle settings in a new and fresh kotlin project and it builds. Unfortunately I couldn't use all your libs and your exact setting but maybe it's just a matter of order. Here is my
build.gradle
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-kapt'
apply plugin: 'kotlin-android-extensions'
kapt {
generateStubs = true
}
android {
compileSdkVersion 26
defaultConfig {
applicationId "nice.fontaine.kottest"
minSdkVersion 21
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation 'com.jakewharton:butterknife:6.1.0'
annotationProcessor 'com.jakewharton:butterknife:6.1.0'
implementation('de.keyboardsurfer.android.widget:crouton:1.8.5#aar') {
exclude group: 'com.google.android', module: 'support-v4'
}
implementation 'com.google.dagger:dagger:2.10'
kapt 'com.google.dagger:dagger-compiler:2.10'
kapt 'com.android.databinding:compiler:3.0.0'
implementation 'de.greenrobot:eventbus:2.4.0'
implementation 'com.mcxiaoke.volley:library:1.0.19'
implementation 'com.google.code.gson:gson:2.8.0'
implementation "com.google.android.gms:play-services-places:11.6.0"
implementation "com.google.android.gms:play-services-plus:11.6.0"
implementation "com.google.android.gms:play-services-analytics:11.6.0"
implementation "com.google.android.gms:play-services-auth:11.6.0"
implementation "com.google.android.gms:play-services-gcm:11.6.0"
implementation "com.google.android.gms:play-services-ads:11.6.0"
implementation "com.android.support:appcompat-v7:26.1.0"
implementation "com.android.support:support-v13:26.1.0"
implementation "com.android.support:recyclerview-v7:26.1.0"
implementation "com.android.support:design:26.1.0"
implementation "com.android.support:support-annotations:26.1.0"
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.android.support:multidex:1.0.2'
implementation 'commons-io:commons-io:2.4'
implementation 'org.apache.commons:commons-lang3:3.1'
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.amulyakhare:com.amulyakhare.textdrawable:1.0.1'
implementation 'com.google.ads.mediation:facebook:4.26.1.0'
implementation 'com.facebook.android:audience-network-sdk:4.26.1'
implementation 'org.jboss.netty:netty:3.2.10.Final'
//Testing
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:1.10.19'
androidTestImplementation 'com.android.support:multidex:1.0.2'
androidTestImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test.espresso:espresso-web:3.0.1'
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test:runner:0.3') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test:rules:0.3') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test.espresso:espresso-intents:2.2') {
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
}
androidTestImplementation('com.android.support.test.espresso:espresso-contrib:2.2') {
exclude group: 'com.android.support', module: 'app-compat'
exclude group: 'com.android.support', module: 'support-v4'
exclude group: 'com.android.support', module: 'support-annotations:22.2.1'
exclude module: 'recyclerview-v7'
}
androidTestImplementation 'com.android.support.test.uiautomator:uiautomator-v18:2.1.3'
androidTestImplementation "com.android.support:support-annotations:26.1.0"
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
debugImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRT:0.9.5.3'
releaseImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRTNoOp:0.9.5.3'
testImplementation 'com.letv.sarrsdesktop:BlockCanaryExJRTNoOp:0.9.5.3'
implementation 'me.mvdw.recyclerviewmergeadapter:recyclerviewmergeadapter:2.0.0'
debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.5.1'
releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
testImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
implementation "com.squareup.retrofit2:retrofit:2.3.0"
implementation 'com.squareup.okhttp3:logging-interceptor:3.8.0'
implementation "com.squareup.retrofit2:converter-gson:2.3.0"
implementation "com.squareup.retrofit2:adapter-rxjava2:2.3.0"
implementation 'io.reactivex.rxjava2:rxjava:2.1.2'
implementation 'io.reactivex.rxjava2:rxandroid:2.0.1'
implementation 'com.gojuno.koptional:koptional-rxjava2-extensions:1.2.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
implementation 'com.newrelic.agent.android:android-agent:5.14.0'
implementation 'org.jsoup:jsoup:1.10.3'
}
At least I can verify with this test that
kapt 'com.android.databinding:compiler:3.0.0'
is working for me. Maybe try it in a new project too and check if this works and then slowly apply your other libs one by one. Hope that gets you on track!
Just remove the Kotlin library. Android Stidio 3.0 supports it by default.