Android studio之编译提示Could not find :umeng-asms-v1.2.1

1 、问题

java 复制代码
Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
> Could not resolve all task dependencies for configuration ':app:debugCompileClasspath'.
   > Could not find :umeng-asms-v1.2.1:.
     Required by:
         project :app
   > Could not find :umeng-apm-v1.2.0:.
     Required by:
         project :app

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html

只要提示这种Could not find :可能arr包没有引入正确,可能少了dirs

我的是gradle 8.0,在setting gradle文件添加代码

flatDir { dirs 'app/libs' }

java 复制代码
dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()

        flatDir {
            dirs 'app/libs'
        }
    }
}
相关推荐
_一条咸鱼_1 小时前
Android Glide 的显示与回调模块原理分析
android
_一条咸鱼_1 小时前
Android Glide 图片解码与转换模块原理分析
android
QING6181 小时前
Android_BLE开发——扫描
android·kotlin·app
QING6181 小时前
Android_BLE开发——绑定
android·kotlin·app
顾林海1 小时前
深入理解 Dart 函数:从基础到高阶应用
android·前端·flutter
QING6181 小时前
Android_BLE开发——连接
android·kotlin·app
QING6181 小时前
Android_BLE开发——优化(深入解决 STATUS=133 连接错误)
android·kotlin·app
QING6181 小时前
Android_BLE开发——读写
android·kotlin·app
_一条咸鱼_2 小时前
Android Glide 缓存模块源码深度解析
android
harry235day2 小时前
kotlin 协程创建启动 源码初探(一)
android·kotlin