简体   繁体   English

无法修复:找不到 kotlin-reflect-1.3.72.jar (org.jetbrains.kotlin:kotlin-reflect:1.3.72)

[英]cannot fix: Could not find kotlin-reflect-1.3.72.jar (org.jetbrains.kotlin:kotlin-reflect:1.3.72)

i pulled code that my frined wrote and now i got this error:我提取了我的朋友写的代码,现在我得到了这个错误:

Could not find kotlin-reflect-1.3.72.jar (org.jetbrains.kotlin:kotlin-reflect:1.3.72).
Searched in the following locations:
    https://jcenter.bintray.com/org/jetbrains/kotlin/kotlin-reflect/1.3.72/kotlin-reflect-1.3.72.jar

how ever my fried didn't used any kotlin code or plugin.我的油炸怎么没有使用任何 kotlin 代码或插件。

i try to:我试着:

  1. download the library he telling me to and adding it.下载他告诉我的库并添加它。
  2. adding the dependencies:添加依赖项:
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"实施“org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version”
    classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"类路径“org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version”
    compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8"编译“org.jetbrains.kotlin:kotlin-stdlib-jdk8”
  3. add maven { url "https://jitpack.io" }添加 maven { url "https://jitpack.io" }
  4. clean project清洁项目
  5. restart Android studio and my PC重启 Android studio 和我的电脑
  6. delete gradle cash (it failed to do so)删除 gradle 现金(它没有这样做)

my friend dont get this error but i do and when i go back in the versions the error disappear but then we lose our code. 我的朋友没有收到此错误,但我收到了,当我 go 回到版本时,错误消失了,但随后我们丢失了代码。
i feel like im out of options 我觉得我别无选择

this is my gradle(app):这是我的 gradle(应用程序):

 apply plugin: 'com.android.application' android { compileSdkVersion 29 buildToolsVersion "29.0.3" defaultConfig { applicationId "com.example.rems" minSdkVersion 17 targetSdkVersion 29 versionCode 1 versionName "1.0" vectorDrawables.useSupportLibrary = true testInstrumentationRunner "androidx.mini_window_style.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } sourceSets { main { resources { srcDirs 'src/main/resources' } java { srcDirs 'src/main/java', 'src/main/java/module' } } } compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } } dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'androidx.appcompat:appcompat:1.1.0' implementation 'androidx.constraintlayout:constraintlayout:1.1.3' implementation 'androidx.navigation:navigation-fragment:2.1.0' implementation 'androidx.navigation:navigation-ui:2.1.0' implementation 'androidx.legacy:legacy-support-v4:1.0.0' implementation 'androidx.viewpager2:viewpager2:1.0.0' implementation 'com.google.android.material:material:1.1.0' implementation files('libs\\natty-0.13.jar') implementation files('libs/antlr-4.9-complete.jar') implementation files('libs\\antlr-4.9-complete.jar') implementation files('libs\\slf4j-android-1.7.30.jar') testImplementation 'junit:junit:4.12' implementation 'org.slf4j:slf4j-api:1.7.30' androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' //noinspection GradleCompatible implementation "com.android.support:support-compat:28.0.0" implementation files('libs\\natty-0.13.jar') implementation files('libs\\antlr-4.9-complete.jar') }

and that's my gradle(android project):这就是我的 gradle(android 项目):

 // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { google() jcenter() } dependencies { classpath 'com.android.tools.build:gradle:4.1.1' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } } allprojects { repositories { google() jcenter() } } task clean(type: Delete) { delete rootProject.buildDir }

Your build.gradle(Project:android) file should look something like this:您的build.gradle(Project:android)文件应如下所示:

buildscript {
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath "com.android.tools.build:gradle:3.4.1"
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.31"
    }
}

allprojects {
    repositories {
        google()
        jcenter()
    }
}

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

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法下载 kotlin-reflect.jar (org.jetbrains.kotlin:kotlin-reflect:1.3.0):没有可用于离线模式的缓存版本 - Could not download kotlin-reflect.jar (org.jetbrains.kotlin:kotlin-reflect:1.3.0): No cached version available for offline mode Kotlin 错误:找不到 org.jetbrains.kotlin:kotlin-stdlib-jre7:1.0.7 - Kotlin Error : Could not find org.jetbrains.kotlin:kotlin-stdlib-jre7:1.0.7 找不到 arguments [org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.3.50] 的方法 implementation() - Could not find method implementation() for arguments [org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.3.50] 更改实现找不到 org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.21 - change implementation Could not find org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.21 Android Studio-找不到org.jetbrains.kotlin:kotlin-stdlib:1.1.3-2 - Android Studio - Could not find org.jetbrains.kotlin:kotlin-stdlib:1.1.3-2 Gradle 同步失败:找不到 org.jetbrains.kotlin(无意使用 Kotlin) - Gradle sync failed: Could not find org.jetbrains.kotlin (no intention to use Kotlin) Flutter could not download kotlin-compiler-embeddedable-1.5.21.jar (org.jetbrains.kotlin:kotlin-compiler-embeddable-1.5.21.jar - Flutter could not download kotlin-compiler-embeddedable-1.5.21.jar (org.jetbrains.kotlin:kotlin-compiler-embeddable-1.5.21.jar 错误:找不到org.jetbrains.kotlin:kotlin-stdlib-jdk8 - ERROR: Could not find org.jetbrains.kotlin:kotlin-stdlib-jdk8 错误:找不到org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.31 - ERROR: Could not find org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.31 错误:在 Ionic 3 中找不到 org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.60-eap-25 - Error: Could not find org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.60-eap-25 in Ionic 3
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM