3

Error:Execution failed for task ':app:mergeDebugResources'.

Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException: Error:java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:

GRADLE CONSOLE OUTPUT:

Executing tasks: [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies]

Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2510Library UP-TO-DATE
:app:prepareComAndroidSupportAppcompatV72510Library UP-TO-DATE
:app:preDebugAndroidTestBuild UP-TO-DATE
:app:prepareComAndroidSupportMultidex101Library UP-TO-DATE
:app:prepareComAndroidSupportSupportCompat2510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportCoreUi2510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportCoreUtils2510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportFragment2510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportMediaCompat2510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportV42510Library UP-TO-DATE
:app:prepareComAndroidSupportSupportVectorDrawable2510Library UP-TO-DATE
:app:prepareComAndroidVolleyVolley100Library UP-TO-DATE
:app:prepareDebugDependencies
:app:compileDebugAidl UP-TO-DATE
:app:compileDebugRenderscript UP-TO-DATE
:app:generateDebugBuildConfig UP-TO-DATE
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources UP-TO-DATE
:app:mergeDebugResources
Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException: 
:app:mergeDebugResources FAILED

FAILURE: Build failed with an exception.
  • What went wrong: Execution failed for task ':app:mergeDebugResources'.

    Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:

  • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Can anyone help me in fixing this. I am new to android :(

I have added a screen shot of Android Manifest.

So far I have tried below steps to fix the issue. Still no help.
1) Clean Prjoect
2) Rebuild Project
3) File > Invalid Cache/Restart

build.gradle

apply plugin: 'com.android.application'

android {
    compileSdkVersion 25
    buildToolsVersion "25.0.2"
    defaultConfig {
        applicationId "com.theaquarious.myfavapp"
        minSdkVersion 14
        targetSdkVersion 25
        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 {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile 'com.android.support:appcompat-v7:25.1.0'
    testCompile 'junit:junit:4.12'
    compile 'com.mcxiaoke.volley:library:1.0.19'
}
5
  • Please add your app build.gradle. Commented Jan 30, 2017 at 9:44
  • I have added the build.gradle Commented Jan 30, 2017 at 10:14
  • You use a deprecated library of volley. Try using compile 'com.android.volley:volley:1.0.0' Commented Jan 30, 2017 at 11:16
  • Btw, is the build.gradle the complete version of yours? If you only use 3-4 library, you don't need to enable multidex. So you can set multidex as false with multiDexEnabled false Commented Jan 30, 2017 at 11:19
  • I have used compile 'com.android.volley:volley:1.0.0', still no help Commented Jan 30, 2017 at 12:15

4 Answers 4

2

This issue is now resolved. The error was raised due to the image file. I have changed the extension of an JPG image to PNG without using any editor. Due to this android studio started to throw the error. Thanks to everyone who tried to help me. If anyone needs more clarification on this, just comment.

Sign up to request clarification or add additional context in comments.

1 Comment

I'm facing the same issue. It's not resolving. I haven't made any change in any drawable.
0

This appears to be a bug in aquiring a lock in some Java thread. I see this on my Windows 7 PC starting recently. I have had success by simply running Task Manager and then killing the java.exe process. If I then try again, the build seems to work fine.

Comments

0

The error is because the names of the files that are saved in your Drawable folder can not be capitalized. Rename the file and leave everything in lowercase.

Comments

-1

Don’t save drawable images in capital case and it should be png not jpg else it will throw an error : Execution failed for task ':app:mergeDebugResources'

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.