目标降级 [英] Target Downgrade

查看:79
本文介绍了目标降级的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在应用商店发布了一个应用程序,其目标api是23.用户已经与我联系,通知我我的应用程序在运行23的设备上立即崩溃。经过研究,一个库我的应用程序依赖于崩溃,如果目标是23.我将目标设置为22修复了错误,但是,现在谷歌播放不会让我更新应用程序,因为禁止将先前使用M权限(目标SDK 23及更高版本)的设备降级到使用旧式权限的APK(目标SDK 22及以下版本)。



这是一款付费应用程序,所以我不能将其从商店中删除并以新名称重新发布。任何人都遇到过这个?任何建议?

解决方案

如错误消息所示,一旦您设置 targetSdkVersion 到23,您正在使用 Android 6.0的运行时权限,并且无法降级到较旧的 targetSdkVersion



选择编译,min和targetSdkVerison博客文章 b
$ b


这并不意味着您必须使用所介绍的每项新功能,也不应该在未经测试的情况下盲目更新您的targetSdkVersion- 请在更新targetSdkVersion之前进行测试!您的用户会感谢您。 必须更新你r应用程序与API 23的兼容性,删除专门禁止定位API 23的库,并确保您请求危险运行时权限


I have released an app on the app store with the target api being 23. A user has contacted me informing me that my app immediately crashes on devices running 23. After researching, a library my app is relying on crashes if the target is 23. I set the target to 22 which fixes the error, however, now google play will not let me update the app because "It is forbidden to downgrade devices which previously used M permissions (target SDK 23 and above) to APKs which use old style permissions (target SDK 22 and below)."

This is a paid app so I can't just remove it from the store and republish under a new name. Anyone run into this before? Any advice?

解决方案

As the error message states, once you set your targetSdkVersion to 23, you are using Android 6.0's runtime permissions and cannot downgrade to target an older targetSdkVersion.

As mentioned in the Picking your compile, min, and targetSdkVerison blog post:

That doesn’t mean you have to use every new feature introduced nor should you blindly update your targetSdkVersion without testing  — please, please test before updating your targetSdkVersion! Your users will thank you.

You'll have to update your app's compatibility with API 23, removing libraries that specifically prohibit targeting API 23 and ensuring that you request dangerous permissions at runtime.

这篇关于目标降级的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆