Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

google play service error

I got this below error

Error:(1, 1) A problem occurred evaluating project ':app'.
> Failed to apply plugin [id 'com.android.application']
   > Gradle version 2.10 is required. Current version is 2.8. If using the gradle wrapper, try editing the distributionUrl in C:\Users\TARUN\Desktop\GingerBuds\gradle\wrapper\gradle-wrapper.properties to gradle-2.10-all.zip

Then I changed the above gradle path, Then following problem occurred,

I am getting this exception, while building my project . I rebuild and clean the project and updated google-play-services , then also i got error. can anyone please help me how to solve this.

Error:Execution failed for task ':app:compileDebugJavaWithJavac'.
java.io.FileNotFoundException: C:\Users\TARUN\Desktop\Gingerbuds\app\build\intermediates\exploded-aar\com.google.android.gms\play-services\8.4.0\jars\classes.jar (The system cannot find the path specified)

Build.gradle

apply plugin: 'com.android.application'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.1"

    defaultConfig {
        applicationId "com.kitchenvilla.gingerbuds"
        minSdkVersion 15
        targetSdkVersion 23
        versionCode 24
        versionName "1.2.2"
    }
    buildTypes {
        release {
            minifyEnabled true
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
}

android {
    useLibrary 'org.apache.http.legacy'
}
android {
    publishNonDefault true
}


dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:recyclerview-v7:23.0.0'
    compile 'com.mcxiaoke.volley:library:1.0.15'
    compile 'org.apmem.tools:layouts:1.10@aar'
    compile 'com.android.support:appcompat-v7:23.0.0'
    compile 'com.android.support:design:23.0.0'
    compile 'com.google.android.gms:play-services-maps:8.4.0'
    compile 'com.google.android.gms:play-services:8.4.0'
    compile 'com.android.support:support-v4:23.0.0'
    compile 'com.pkmmte.view:circularimageview:1.1'
    compile 'com.squareup.picasso:picasso:2.3.2'
    compile 'com.facebook.android:facebook-android-sdk:4.7.0'
}
like image 463
tvtv Avatar asked Jan 15 '16 08:01

tvtv


People also ask

Why is my play store services not working?

Check that you have a strong Wi-Fi or mobile data connection After you check your internet connection, try your download again. To get more help with connection problems, go to Fix internet connection problems on Android devices.


2 Answers

This bug has been fixed according to Google dev blog: http://tools.android.com/tech-docs/new-build-system

2.0.0-alpha6 (2016/1/15)
Instant Run 
Fix alpha5 reported issues :
    - cannot build when importing play-services.

You should update android gradle tools version

dependencies {
    classpath 'com.android.tools.build:gradle:2.0.0-alpha6'
}
like image 101
ArL Avatar answered Nov 15 '22 06:11

ArL


This exception is thrown during a failed attempt to open the file denoted by a specified Path-name.

You can use

   compile 'com.google.android.gms:play-services:8.3.0'

Update your classpath

 classpath 'com.android.tools.build:gradle:2.0.0-alpha2'
like image 33
IntelliJ Amiya Avatar answered Nov 15 '22 04:11

IntelliJ Amiya