Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.5.0-runtime

2023-05-16

冲突问题

androidx和support类冲突,具体如下:

Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub$Proxy found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver$Stub found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver$Stub$Proxy found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$1 found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$MyResultReceiver found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$MyRunnable found in modules core-1.5.0-runtime (androidx.core:core:1.5.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)

Go to the documentation to learn how to Fix dependency resolution errors.

解决办法

在工程中 gradle.properties 中加入配置:android.enableJetifier=true

在这里插入图片描述

说明

其实在出错的同时也有这么断错误:

AGPBI: {“kind”:“warning”,“text”:“Your project has set android.useAndroidX=true, but configuration :player:debugRuntimeClasspath still contains legacy support libraries, which may cause runtime issues.\nThis behavior will not be allowed in Android Gradle plugin 8.0.\nPlease use only AndroidX dependencies or set android.enableJetifier=true in the gradle.properties file to migrate your project to AndroidX (see https://developer.android.com/jetpack/androidx/migrate for more info).\nThe following legacy support libraries are detected:\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.github.bumptech.glide:gifdecoder:4.9.0 -> com.android.support:support-annotations:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> com.android.support:support-compat:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> com.android.support:support-compat:27.1.1 -> android.arch.lifecycle:runtime:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> android.arch.lifecycle:livedata-core:1.1.0 -> android.arch.lifecycle:common:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> android.arch.lifecycle:livedata-core:1.1.0 -> android.arch.core:common:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> com.android.support:support-core-ui:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> com.android.support:support-core-utils:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> android.arch.lifecycle:livedata-core:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> android.arch.lifecycle:livedata-core:1.1.0 -> android.arch.core:runtime:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:support-fragment:27.1.1 -> android.arch.lifecycle:viewmodel:1.1.0\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:animated-vector-drawable:27.1.1\n:player:debugRuntimeClasspath -> project :listplayer -> com.github.bumptech.glide:glide:4.9.0 -> com.android.support:animated-vector-drawable:27.1.1 -> com.android.support:support-vector-drawable:27.1.1”,“sources”:[{}]}

Your project has set android.useAndroidX=true, but configuration :player:debugRuntimeClasspath still contains legacy support libraries, which may cause runtime issues.
This behavior will not be allowed in Android Gradle plugin 8.0.
Please use only AndroidX dependencies or set android.enableJetifier=true in the gradle.properties file to migrate your project to AndroidX (see https://developer.android.com/jetpack/androidx/migrate for more info).
The following legacy support libraries are detected:

工具已经提示我们怎么处理了。工程已经配置了androidx,但又配置了support 的库,运行的时候可能会发生错误。请仅使用androidx的依赖或者在gradle.properties中添加android.enableJetifier=true将support库转换为androidx的依赖。

其次,个人在使用过程中,遇见了1.5 / 1.7的冲突,只有INotificationSideChannel和os.ResultReceiver两个类冲突。若不是可以配置android.enableJetifier=true将其转换,各种依赖查询,各种exclude要死人的。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.5.0-runtime 的相关文章

  • EditText 中的验证允许 IP 或 Web Url 主机

    我需要对我的 EditText 进行验证 以便它允许我输入有效的 IP 地址格式 即示例 132 0 25 225 or 网址格式 www 例如 www example com 逻辑是 如果用户首先输入任何数值 则验证 IP 将执行操作 否
  • Android 主机意图过滤器通配符

    是否可以在 android host 属性上使用通配符 就像是 android host site com android pathPattern android pathPrefix m android scheme http gt Or
  • 如何检测和管理来电(Android)?

    我想创建一个应用程序 可以检测来电并在一定数量的蜂鸣声 响铃 后启动我的自定义活动 我的意思是在 2 或 3 或 5 声蜂鸣声 响铃 后我的activity被触发 我该怎么做 Thanks 我认为您无法计算自来电开始以来电话响了多少次 无法
  • Android 上的 Firebase:如何检查 Firebase 身份验证失败原因?

    我在 Android 上使用 Firebase 和 Firebase Auth 功能 I try FirebaseAuth signInWithEmailAndPassword如果失败 我想知道为什么登录过程失败 The signInWit
  • 显示警报或收到通知时的视图

    我正在关注this http tokudu com 2010 how to implement push notifications for android 显示的教程通知 on an 安卓设备 当我在设备上运行该应用程序时 状态栏上会出现
  • 使用 APDU 命令的有效 NFC 读取比特率是多少?

    我目前正在使用 Android IsoDep trancieve 函数发送和接收累计 1628 字节的数据 该函数分布在 35 个 APDU 命令 选择应用程序 身份验证 读取 中 字节计数包括返回的 MAC 校验和以及由 transcie
  • Android Studio - 错误:未捕获翻译错误:com.android.dx.cf.code.SimException:本地 0001:无效

    我刚刚使用 Android Studio 设置了一台新计算机 并从 bitbucket 导入了我的项目 问题是我现在在尝试构建项目时遇到此错误 信息 Gradle 任务 app clean app generateDebugSources
  • 如何将 EditText 传递给另一个活动?

    Intent intent new Intent this Name class intent putExtra key et getText toString startActivity intent Intent intent getI
  • SQLite (Android):使用 ORDER BY 更新查询

    Android SQLite 我想要在 myTable 中的其他行之间插入行在android中使用SQLite 为此 我尝试增加从第 3 行开始的所有行的 id 这样 我就可以在位置 3 处插入新行 myTable 的主键是列 id 表中没
  • 按钮未显示在屏幕上

    我创建了一个应用程序 其中显示带有图像和文本的列表视图 我在页面末尾添加按钮 但这没有显示在屏幕上 我是 Android 新手 我该如何解决这个问题 这是我的 UI XML 代码
  • 连接到不可发现的蓝牙设备

    我正在开发一个安卓应用程序 只是一个一般性问题 是否可以连接到公开不可发现的设备 提前致谢 如果您之前已与该设备配对 则即使该设备未处于可发现模式 也可以再次连接到该设备 参见这篇文章 以编程方式连接到配对的蓝牙设备 https stack
  • 为什么按钮上的 maxWidth 不起作用以及如何解决它?

    我的布局上有两个按钮 在大屏幕设备 平板电脑 上我想限制它们的宽度 这样它们看起来就不会很荒谬 我希望使用 maxWidth 属性 但它显然在我的场景中没有任何作用 这是布局定义 按钮使用布局的整个宽度 忽略 maxWidth 中的任何值
  • AnalyticsService 未在应用程序清单中注册 - 错误

    我正在尝试使用 sdk 中提供的以下文档向 Android 应用程序实施谷歌分析服务 https developers google com analytics devguides collection android v4 https d
  • 如何从android获取应用程序安装时间

    我尝试了一些方法 但没有成功 请帮助我 PackageManager pm context getPackageManager ApplicationInfo appInfo pm getApplicationInfo app packag
  • 在 AppAuth-Android 中注销

    我有一个用JAVA开发的Android应用程序 对于这个应用程序 我使用的是身份服务器4 https github com IdentityServer IdentityServer4作为我的 STS 一切正常 但我找不到任何注销的实现Ap
  • 如何在Android Compose中使用otf类型字体文件?

    我正在学习使用 Android Jetpack Compose 现在我有一个正则 otf字体文件在资产 字体 我想在文本中使用它 java lang RuntimeException Font asset not found commonu
  • 删除Android所有语言中的字符串

    我有一个包含多个翻译的应用程序 我想删除一些字符串 我怎样才能重构并删除它们一次 例如在默认情况下strings xml文件并自动将删除传播到其他翻译的其他 strings xml 文件 您可以通过 Android Studio 中的 翻译
  • 在 Android 中上传文件出现内存不足错误

    我的上传代码如下 String end r n String twoHyphens String boundary try URL url new URL ActionUrl HttpURLConnection con HttpURLCon
  • 通过powershell运行ADB命令

    所以我尝试通过 powershell 脚本运行一些 ADB 命令 这是我正在尝试做的一个简单示例 adb shell echo in adb shell su root echo you are now root ls cd data da
  • Android ADT Eclipse 插件,parseSDKContent 失败

    我刚刚设置了我的第一个 Android 开发环境 其中包括 日食3 5 Mac OS X 10 5 适用于 x86 mac 的 Android SDK ADT Eclipse 插件 0 9 6 我已将 set PATH 设置为我的 SDK

随机推荐