I am getting this error while trying to build the APK file of the project.
This is my Gradle file
apply plugin: 'com.android.application'
apply plugin: 'realm-android'
android {
compileSdkVersion 34
defaultConfig {
applicationId ""
minSdkVersion 21
targetSdkVersion 34
versionCode 1
versionName "1.0.0"
multiDexEnabled true
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation 'androidx.recyclerview:recyclerview:1.3.2'
implementation 'androidx.cardview:cardview:1.0.0'
implementation 'com.google.android.material:material:1.11.0'
//okhttp logging interceptor
implementation 'com.squareup.okhttp3:logging-interceptor:4.12.0'
//Retrofit Library
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
implementation 'io.github.shashank02051997:FancyToast:2.0.2'
//External Libraries-------------------
implementation 'io.realm:android-adapters:1.4.0'
implementation 'com.github.ceryle:RadioRealButton:v1.3'
implementation 'com.yarolegovich:lovely-dialog:1.1.1'
implementation 'de.hdodenhof:circleimageview:3.1.0'
}
I tried all the solutions in Stack Over Flow but not able to find the reason for this, Can Someone please explain me that why I am getting this error and what is the solution for this?
By seeing the attached screenshots
I think this could be because by default (gradle.properties)
android.enableR8.fullMode=truemake itandroid.enableR8.fullMode=falseand trying it will create the APK