Gradle error when clicking "run application" - Android Studio 0.4.3 [Failed to create an instance of the toolkit API]

I get this error when I click "run application". I have been looking for a fix for the last two days, can you help me?

I have Android Studio 0.4.3 installed, this problem started when my school updated Java on my school computer.

org.gradle.tooling.GradleConnectionException: Failed to create an instance of the Tooling API implementation using the specified Gradle distribution ' http://services.gradle.org/distributions/gradle-1.9-all.zip ': Failed to create an instance of the Tooling API implementation with using the specified Gradle distribution http://services.gradle.org/distributions/gradle-1.9-all.zip '.

    buildscript {
    repositories {
        mavenCentral()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:0.7.+'
    }
}
apply plugin: 'android'

repositories {
    mavenCentral()
}

android {
    compileSdkVersion 19
    buildToolsVersion "19.0.0"

    defaultConfig {
        minSdkVersion 11
        targetSdkVersion 19
    }
    buildTypes {
        release {
            runProguard false
            proguardFile getDefaultProguardFile('proguard-android.txt')
        }
    }
    productFlavors {
        defaultFlavor {
            proguardFile 'proguard-rules.txt'
        }
    }
}

dependencies {
    compile 'com.android.support:appcompat-v7:+'
    compile 'com.android.support:appcompat-v7:18.0.+'
}

This did not solve the problem:

+3
source share
1 answer

Close Android Studio, make a backup and delete all these files from your studio installation directory and run it again, maybe this will help you

android-studio/plugins/android/lib/builder-0.6.1.jar
android-studio/plugins/android/lib/builder-model-0.6.1.jar
android-studio/plugins/gradle/lib/gradle-base-services-1.8.jar
android-studio/plugins/gradle/lib/gradle-build-setup-1.8.jar
android-studio/plugins/gradle/lib/gradle-core-1.8.jar
android-studio/plugins/gradle/lib/gradle-messaging-1.8.jar
android-studio/plugins/gradle/lib/gradle-native-1.8.jar
android-studio/plugins/gradle/lib/gradle-plugins-1.8.jar
android-studio/plugins/gradle/lib/gradle-tooling-api-1.8.jar
android-studio/plugins/gradle/lib/gradle-wrapper-1.8.jar
android-studio/plugins/gradle/lib/guava-11.0.2.jar

, .

+1

Source: https://habr.com/ru/post/1527337/


All Articles