Android Studio 2.0 Preview: ':app:transformClassesWithInstantRunForDebug' FAILED

前端 未结 4 667
伪装坚强ぢ
伪装坚强ぢ 2020-12-09 08:46

I\'m getting this error in Gradle in Android Studio:

:cart:transformClassesWithInstantRunForDebug FAILED
 Error:Execution failed for task  :cart:transformCla         


        
相关标签:
4条回答
  • This problem happen when the used gradle have problem with instant run.
    So to solve this you have to either change gradle version or disable instant run.

    0 讨论(0)
  • 2020-12-09 08:59

    Resolved :

    Disable the Instant Run option in Android Studio 2.0 Preview

    0 讨论(0)
  • 2020-12-09 09:12

    In my nexus 5 I have get only warrning, but another devices not complied, so I have disabled debug mode if i need it /

    buildTypes {
        release {
            debuggable false
            minifyEnabled true
            proguardFiles 'proguard-android.txt', 'proguard-rules.pro'
        }
        debug {
            debuggable false
            minifyEnabled false
            proguardFiles 'proguard-android.txt', 'proguard-rules.pro'
        }
    } 
    
    0 讨论(0)
  • 2020-12-09 09:17

    Something you can try is deleting the build folder. That does not always work but fixes it sometimes.

    rm -rf cart/build
    

    If that does not work. Run that command then in Android Studio select invalidate caches and restart.

    0 讨论(0)
提交回复
热议问题