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'
        }
    }
}
相关推荐
sc.溯琛5 小时前
MySQL 高级实战:触发器、事务与数据库备份恢复全攻略
android·adb
zhuzewennamoamtf6 小时前
Linux SPI设备驱动
android·linux·运维
雨声不在9 小时前
gradle编译missing_rules报错处理
android·gradle·agp8
用户70937225385111 小时前
配置vscode阅读Android native 代码
android
tangweiguo0305198711 小时前
Android OpenGL ES 2.0 完整开发指南:从零到三维旋转立方体
android
龚礼鹏11 小时前
AndroidStudio module编译aar混淆文件处理
android
jugt13 小时前
将JetBrains系软件(PhpStorm、IntelliJIdea、WebStorm)缓存目录迁移到其它盘
ide·phpstorm
程序员阿鹏13 小时前
MySQL中给字段添加唯一约束的方式有哪些?
android·数据库·mysql
三少爷的鞋15 小时前
Android Data 层设计的四条红线:为什么必须坚持、如何落地
android
猫豆~15 小时前
zabbix实战——3day
android