我正在尝试安装以下依赖项:https://github.com/rubensousa/BottomSheetBuilder

但这给了我以下错误:

android - 无法解析':app @ debug/compileClasspath'的依赖项:无法解析com.github.rubensousa:bottomsheetbuilder:1.6.1-LMLPHP

我无法理解可能由于错误而导致的错误。

这是我正在使用的build.gradle文件。

buildscript {
    repositories {
        jcenter()
        maven { url "https://maven.google.com" }
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.1.3'
    }
}

apply plugin: 'com.android.application'

android {
    compileSdkVersion 27
    defaultConfig {
        applicationId "com.exoplayer"
        minSdkVersion 21
        targetSdkVersion 26
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

repositories {
    mavenCentral()
    maven { url 'https://jitpack.io' }
    maven { url "https://maven.google.com" }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.android.support:appcompat-v7:27.1.1'
    implementation 'com.android.support.constraint:constraint-layout:1.1.0'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
    implementation 'com.github.rubensousa:previewseekbar:2.0.0'
    implementation 'com.github.rubensousa:previewseekbar-exoplayer:2.8.1.0'
    implementation 'com.google.android.exoplayer:exoplayer:2.8.1'
    implementation 'com.github.bumptech.glide:glide:4.7.1'
    annotationProcessor 'com.github.bumptech.glide:compiler:4.7.1'
    implementation 'com.github.rubensousa:bottomsheetbuilder:1.6.1'
    implementation 'com.android.support:design:27.1.1'
}


我哪里错了?

最佳答案

日志在测试包上显示错误。检查您的测试包,以查看是否未删除其类。
只是为了自己检查,请注释测试依赖项,然后再次构建以查看是否仍然存在错误

关于android - 无法解析':app @ debug/compileClasspath'的依赖项:无法解析com.github.rubensousa:bottomsheetbuilder:1.6.1,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/52353028/

10-12 06:15