简体   繁体   English

如果生成构建存在,则无法安装适用于Android的Crashlytics Beta版本:'该软件包与现有软件包冲突,名称相同'

[英]Crashlytics Beta build for Android will not install if production build exists: 'The package conflicts with an existing package by the same name'

Our team distributes beta build through Crashlytics and most of us have the production build installed on our phones. 我们的团队通过Crashlytics分发beta版本,我们大多数人都在手机上安装了生产版本。 We aren't able to install the beta build without removing the production app. 我们无法在不删除生产应用的情况下安装测试版。 (Both builds have different applicationId, as in: prod: com.abc beta: com.abc.beta ) (两个版本都有不同的applicationId,如:prod: com.abc beta: com.abc.beta

We tried using the same keystore (as production) and also a different one to sign the beta build, but it doesn't change anything. 我们尝试使用相同的密钥库(作为生产),也使用不同的密钥库来签署beta版本,但它不会改变任何内容。

Is there a way to install both beta and production builds on the same device? 有没有办法在同一设备上安装beta版和生产版?

After investigating the issue for some time, and thanks to the help from the Fabric team, I've managed to found the issue and also a way to resolve it. 在对该问题进行了一段时间的调查之后,并且感谢Fabric团队的帮助,我设法找到了问题,并找到了解决问题的方法。

Using adb logcat , I've found the underlying error of the failure: 使用adb logcat ,我发现了失败的潜在错误:

Package attempting to redeclare permission com.abc.permission.C2D_MESSAGE already owned by 

It appears that the beta app is trying to write to the same permission file that's owned by the production build. 看来beta应用程序正在尝试写入生产版本所拥有的同一权限文件。 To avoid that, I edited my AndroidManifest.xml as follows: 为了避免这种情况,我按如下方式编辑了我的AndroidManifest.xml

<uses-permission android:name="${applicationId}.permission.C2D_MESSAGE" />
<permission android:name="${applicationId}.permission.C2D_MESSAGE" android:protectionLevel="signature" />

So that the beta app has its own permission folder to write to. 这样beta应用程序就有自己的权限文件夹来写入。

Hope this helps someone out there! 希望这有助于那里的人!

Mike from Fabric here. 来自Fabric的Mike来自这里。 There is an Apple restriction that only allows Testflight or Mobile Device Manager's from installing an app with the same bundle id, so we're prevented from installing over a version installed from the App Store if the bundle id is the same. Apple限制只允许Testflight或移动设备管理器安装具有相同软件包ID的应用程序,因此如果软件包ID相同,我们将无法安装从App Store安装的版本。 For example, you couldn't install a beta production version of the app over the App Store production version. 例如,您无法在App Store生产版本上安装该应用程序的beta版本。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Android - 程序包与现有程序包的名称相同 - Android - The package conflicts with an existing package by the same name 新:程序包与同名的现有程序包冲突 - NEW : the package conflicts with an existing package by the same name 包与同名的现有包冲突 - package conflicts with an existing package by the same name Android应用程序在同一设备上有多个APK“…程序包与同名的现有程序包冲突。” - Android Application multiple APKs on same device “…package conflicts with an existing package by the same name.” 程序包与同名的现有程序包冲突(不建议卸载) - Package conflicts with an existing package by the same name(Not prefare to Uninstall) Gettting“未安装Android应用程序。 在安装新版本时,软件包与现有软件包的名称相同 - Gettting “Android App Not Installed. The package conflicts with an existing package by the same name” when installing new version 新的Android Gradle Build System构建配置包名称与Provider Authority的冲突 - New Android Gradle Build System build configs package name conflicts with Provider Authority Android 应用程序未安装。 现有的同名 package - Android App Not Install. An existing package by the same name Android 应用程序具有不同的构建类型,具有相同的 package 名称 - Android application with different build type having same package name Android - 应用程序未安装为 package 与现有 package 冲突 - Android - App not installed as package conflicts with an existing package
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM