-
-
Notifications
You must be signed in to change notification settings - Fork 312
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
华为获取报错 Lcom/huawei/hms/ads/identifier/AdvertisingIdClient #67
Comments
你没有使用移动安全联盟SDK,无需排除华为官方广告标识服务SDK,去掉 |
移动安全联盟SDK有新版本集成了华为最新的官方广告标识服务SDK吗?我们的移动安全联盟sdk版本用的华为sdk还是旧的,跟华为官方的广告标识服务sdk版本冲突了。 |
我也发生了以上问题 用二楼的方法移除exclude部分,发生编译错误 Failed to resolve: com.huawei.hms:ads-identifier:3.4.62.300错误,暂时不知道如何解决。 |
点击 file -> invalid caches and restart 试试 |
不排除华为SDK,若出现Failed to resolve: com.huawei.hms...,添加华为SDK仓库试试:
|
@liyujiang-gzu 问题得到解决 非常感谢! |
错误信息
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/huawei/hms/ads/identifier/AdvertisingIdClient;
at com.github.gzuliyujiang.oaid.impl.HuaweiImpl.doGet(HuaweiImpl.java:66)
at com.github.gzuliyujiang.oaid.DeviceID.getOAID(DeviceID.java:127)
at com.nextjoy.star.main.activity.SplashActivity.initOaid(SplashActivity.kt:114)
at com.nextjoy.star.main.activity.SplashActivity.getPermission(SplashActivity.kt:89)
at com.nextjoy.star.main.activity.SplashActivity.initViewDate(SplashActivity.kt:85)
at com.nextjoy.star.main.activity.SplashActivity.initView(SplashActivity.kt:76)
at com.nextjoy.base.activity.BaseActivity.onCreate(BaseActivity.kt:44)
at com.nextjoy.star.main.activity.SplashActivity.onCreate(SplashActivity.kt:41)
我的gradle配置如下
// OAID
implementation(deps.OAIDHelper) {
// 排除掉本项目依赖的华为官方广告标识服务SDK
// 也即是使用移动安全联盟SDK依赖的华为官方广告标识服务SDK
exclude group: 'com.huawei.hms', module: 'ads-identifier'
}
The text was updated successfully, but these errors were encountered: