安卓应用程序突然不与设备兼容。

4
我有一个Android应用程序,已经在Google Play商店上发布了大约两年(https://play.google.com/store/apps/details?id=dkh.idex),支持API级别7和以上以及所有屏幕尺寸。它使用了一些权限(ACCESS_NETWORK_STATE,INTERNET,READ_EXTERNAL_STORAGE,WRITE_EXTERNAL_STORAGE)。
2013年4月22日,我上传了一个版本(版本代码44),在所有用户设备上都运行良好。一个月后,2013年5月22日,我上传了一个带有一些小改动的新版本(版本代码45),但是最近几天(从5月27日开始),很多用户向我抱怨他们的设备不再与我的应用程序的最新版本兼容。这些用户已经使用该应用程序长达两年而没有遇到此类问题。有些设备仍然可以升级到最新版本,但其他设备在尝试升级时会收到设备不兼容的消息(请注意,他们已经安装了旧版本的应用程序)。我能够在一个在Google Play商店中说不兼容的设备上(一个旧版的三星Galaxy Tab 10.1)通过ADB(USB)直接安装该应用程序。
我查看了我的文件的变更集,两个版本之间在AndroidManifest.xml中唯一的更改是更新版本代码和版本号。我没有更改任何使用权限、支持的屏幕尺寸、支持的API级别,甚至没有添加任何活动或更改调试设置。
以下是我的AndroidManifest.xml:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="dkh.idex"
  android:versionName="3.2.11" android:versionCode="45">

<supports-screens
android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:anyDensity="true" />

<uses-sdk android:minSdkVersion="7"/>

<uses-permission android:name="android.permission.INTERNET"></uses-permission>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<application android:name="dkh.classes.MyApp" android:label="@string/app_name"    android:debuggable="false" android:icon="@drawable/ic_launcher_idex_v3">
    <activity android:name=".idex"
              android:label="@string/app_name"
              android:screenOrientation="portrait">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <activity android:name=".Form2"
        android:label="@string/app_name"
        android:screenOrientation="portrait"
        android:configChanges="orientation">

    </activity>
    <activity android:name=".InfoForm"
        android:label="@string/app_name"
        android:screenOrientation="portrait">

    </activity>
    <activity android:name=".INSTAForm"
        android:label="@string/app_name"
        android:launchMode="standard"
        android:screenOrientation="portrait">
    </activity>
    <activity android:name=".HygieneForm"
        android:label="@string/app_name"
        android:screenOrientation="portrait">

    </activity>
    <activity android:name=".CommentForm"
        android:label="@string/app_name"
        android:screenOrientation="portrait">

    </activity>
    <activity android:name=".AddReqChooseForm"
        android:label="@string/app_name"
        android:screenOrientation="portrait">

    </activity>
    <activity android:name=".AddReqForm"
        android:label="@string/app_name"
        android:screenOrientation="portrait">

    </activity>
    <activity android:name=".FTPForm" android:label="@string/app_name" android:screenOrientation="portrait"></activity>
    <activity android:name=".SyncForm" android:label="@string/app_name" android:screenOrientation="portrait"></activity>
    <activity android:name=".DrawTestForm" android:label="@string/app_name"  android:configChanges="keyboardHidden|orientation"></activity>
    <activity android:name="StatisticsForm" android:screenOrientation="portrait" android:label="@string/app_name"></activity>
    <activity android:name="PhotoGallery" android:screenOrientation="portrait" android:label="@string/app_name"></activity>
    <activity android:name="PhotoView" android:label="@string/app_name"></activity>
    <activity android:name="ParametersForm" android:label="@string/app_name" android:screenOrientation="portrait" android:windowSoftInputMode="adjustPan"></activity>
    <activity android:name="PropertiesForm" android:label="@string/app_name" android:screenOrientation="portrait" android:windowSoftInputMode="adjustPan"></activity>
    <activity android:screenOrientation="portrait" android:name="InspectionChangeForm" android:label="@string/app_name"></activity>
    <activity android:name="AdvancedSyncWindow" android:label="@string/app_name" android:screenOrientation="portrait"></activity>
    <service android:process=":image_process" android:name=".ImageUploadService"></service>
    <activity android:name=".HelpWindow" android:label="@string/app_name"></activity>
    <activity android:name="RecoverView"></activity>
    <activity android:name="InspectionCommentForm" ></activity>

</application>
</manifest> `

在我的其余代码中,我已经将一些文本添加到我的资源文件中,并进行了一些标准的微小更改,但这些更改在某种程度上已经存在于应用程序中。
我真的对这个问题感到困惑。有人知道这可能是什么原因,或者是否知道Google是否更改了任何可能影响此问题的内容?如果需要更多信息,请询问。

这个有帮助吗?http://stackoverflow.com/questions/8924752/android-application-no-more-compatible-on-market - Rick77
我无法解释为什么这个问题最近才出现,但你的“supports-screens”元素中缺少“android:xlargeScreens”,这可能是相关的。 - CloudyMusic
@Rick77 看起来他们也建议在清单中添加xlargeScreens,但是之前这并不是问题。不过我稍后会尝试一下。 - Daniel
@cloudymusic 在Android开发者指南中提到,xlargeScreens是在API级别9中引入的,而我的应用程序是API级别7(http://developer.android.com/guide/topics/manifest/supports-screens-element.html#xlarge)。这不意味着xlargeScreens在我的情况下不适用吗? - Daniel
这里也有同样的问题,使用相同版本代码44、45!!!令人毛骨悚然... - David Gras
显示剩余3条评论
1个回答

1

我解决了它。

问题在于Google Play会根据设备屏幕大小过滤应用程序,由于xlargeScreens在API 7(版本2.1)中不受支持,因此这些设备上的过滤器将被设置为false。 直到5月底才开始强制执行此规定。 我的应用程序在完全相同的规格上运行了两年,但我怀疑Google Play已经更新以强制执行此约束。

解决方案:如果您有一个针对API 7开发但希望在xlargeScreens设备上可用的应用程序,则必须在清单中设置

<uses-sdk
    android:minSdkVersion="7"
    android:targetSdkVersion="9" />

如果minSdkVersion或targetSdkVersion中的任何一个大于等于9,Google Play将允许xlargeScreen设备查看您的应用程序。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接