Execution failed for task ':app:processDebugResources' even with latest build tools

前端 未结 10 1933
南笙
南笙 2020-12-03 05:14

I am getting this error when I try to run my project. I have installed the latest build tools- 23.0.3 but still the error persists. How do I fix this?

Execut         


        
10条回答
  •  遥遥无期
    2020-12-03 05:57

    Error:Execution failed for task com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException:

    finished with non-zero exit value 1

    One reason for this error to occure is that the file path to a resource file is to long:

    Error: File path too long on Windows, keep below 240 characters 
    

    Fix: Move your project folder closer to the root of your disk

    Don't:// folder/folder/folder/folder/very_long_folder_name/MyProject...

    Do://folder/short_name/MyProject


    Another reason could be duplicated resources or name spaces

    Example:

      
    

    And make sure all file names and extensions are in lowercase

    Wrong

    myimage.PNG
    myImage.png
    

    Correct

    my_image.png
    

    Make sure to Clean/Rebuild project

    (delete the 'build' folder)

提交回复
热议问题