android - 无法解决 : org. jetbrains.kotlin:kotlin-stdlib

标签 android android-studio gradle kotlin build.gradle

请帮帮我。我的项目有一些问题。
我有这样的错误

ERROR: Failed to resolve: org.jetbrains.kotlin:kotlin-stdlib:1.4-M1-eap-93
ERROR: Failed to resolve: org.jetbrains.kotlin:kotlin-stdlib-common:1.4-M1-eap-93

在我的依赖项 gradle 模块中,我编写了这段代码
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"

这是我的构建脚本
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    ext.kotlin_version = '1.3.70'

    repositories {
        maven {
            url "http://dl.bintray.com/kotlin/kotlin-eap"
        }
        maven { url 'https://maven.fabric.io/public' }
        google()
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.4.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
        classpath 'com.google.gms:google-services:4.3.0'
        classpath 'io.fabric.tools:gradle:1.31.2'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }


}

apply from: 'dependecies.gradle'

allprojects {
    repositories {
        maven {
            url "http://dl.bintray.com/kotlin/kotlin-eap"
        }
        maven { url 'https://maven.fabric.io/public' }
        google()
        jcenter()
        mavenCentral()
        maven { url "https://jitpack.io" }
        maven {
            url "http://dl.bintray.com/glomadrian/maven"
        }
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

我使用 kotlin 版本 1.3.70 和 IDE android studio 版本 3.5.1

最佳答案

将 ext.kotlin_version = '1.3.70' 更改为 ext.kotlin_version = '1.4-M1'

关于android - 无法解决 : org. jetbrains.kotlin:kotlin-stdlib,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60711536/

相关文章:

Android:在 Android Studio 中链接外部静态 C/C++ 库

android - 是否可以在 android studio 中不使用任何 usb 电缆而通过 wifi 进行调试?

android - Web/Android/iOS - 内部链接 - 寻找想法/解决方案。

java - 如何限制文件上传带宽?

android - 如何在 Android Studio 中调整编辑器滚动

Android Studio 项目中的 Gradle 弃用 "Relying on packaging to define the extension of the main artifact..."可以修复吗?

继承人库中不存在Android gradle包R

java - 想法不显示子项目

android - 拒绝访问属性 "vendor.camera.aux.packagelist"

android - dp(密度无关像素)是物理尺寸吗?