I'm getting this error each time I try to give rebuild project
Error: Execution failed for task ': app: transformClassesWithDexForRelease'.
com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException: Error while executing java process with main class com.android.dx.command.Main with arguments {--dex --num-threads = 4 --output C: \ Users \ M \ Documents \ MY_APP_NAME \ app \ build \ media \ transforms \ dex \ release \ folders \ 1000 \ 1f \ main C: \ Users \ M \ Documents \ MY_APP_NAME \ app \ build \ intermediate \ transforms \ proguard \ release \ jars \ 3 \ 1f \ main.jar}
My build.gradle is this:
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "MY_PACKAGE"
minSdkVersion 16
targetSdkVersion 25
versionCode 8
versionName "5.2"
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.google.android.gms:play-services-ads:11.0.1'
compile 'com.google.android.gms:play-services-location:11.0.1'
}
OBS - this occurs in the debug version tb. I'm already freaking out !!! Someone knows what to do ...
Thank you.
EDITED
Now it's popping up that comes with this task:
: app: transformClassesWithDexBuilderForDebug
(last task that appears in the Gradle Console)
and no Messages appears:
Information: Gradle tasks [: app: generateDebugSources, : app: generateDebugAndroidTestSources,: app: mockableAndroidJar] Error: Failed to complete Gradle execution.
Cause: An existing connection was terminated by the host remote
I tried to upgrade my gralde.build to the latest versions of the tools, but nothing tb.
apply plugin: 'com.android.application'
android {
compileSdkVersion 27
buildToolsVersion "27.0.3"
defaultConfig {
applicationId "MY_PACKAGE"
minSdkVersion 16
targetSdkVersion 27
versionCode 8
versionName "5.2"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:27.0.2'
compile 'com.google.android.gms:play-services-ads:11.8.0'
compile 'com.google.android.gms:play-services-location:11.8.0'
compile 'com.android.support:multidex:1.0.2'
compile project(':adcolony-sdk-3.1.2')
compile 'com.squareup.picasso:picasso:2.5.2' //for Inmobi
}
add in Android Manifets the multiDex tag, but nothing tb.
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:name="android.support.multidex.MultiDexApplication" >
Funny that my app is already published (to try to update only), this only started to happen in this new version of Android Studio (3.0.1), q alias ends with PC RAM !!! I tried to uninstall this version and install the old one, but then tb error appears.
Does anyone know how to solve the problem? Thank you.