简体   繁体   English

Android:解析清单时解析错误。停止安装

[英]Android: Parse error when parsing manifest. Discontinuing installation

I know this question has been asked to death here, but I am unable to find the solution in all of the offered answers and its driving me crazy. 我知道这个问题已经在这里被要求死了,但是我无法在所有提供的答案中找到解决方案而且它让我疯狂。

I have an app which I have set up to download updates from my own server. 我有一个应用程序,我已设置从我自己的服务器下载更新。 This update installs fine on some types of phones but fails on others (namely the Droid Incredible 2). 此更新在某些类型的手机上安装正常但在其他手机上安装失败(即Droid Incredible 2)。

The error it alerts when I try to install an update on SOME phones is: 我尝试在SOME手机上安装更新时发出的错误是:

"Parse Error: There is a problem parsing the package." “解析错误:解析包时出现问题。”

The logcat shows: logcat显示:

INFO/ActivityManager(1482): Starting activity: Intent { act=android.intent.action.VIEW dat=file:///mnt/sdcard/download/application.apk typ=application/vnd.android.package-archive cmp=com.android.packageinstaller/.PackageInstallerActivity } from pid 4620
WARN/PackageParser(2528): Skipping dir: /mnt/sdcard/download/application.apk
WARN/PackageInstaller(2528): Parse error when parsing manifest. Discontinuing installation
  1. I am signing and exporting this app with a valid key, using the Eclipse tool, with MinSDK version 3. 我使用Eclipse工具和MinSDK版本3签署并使用有效密钥导出此应用程序。
  2. I am making certain that the version code in the downloaded app is higher than that of the existing app. 我确定下载的应用程序中的版本代码高于现有应用程序的版本代码。
  3. I am making sure that the .apk filename is the same in both apps. 我确保两个应用程序中的.apk文件名相同。

What else could I possibly be doing wrong? 还有什么我可能做错了?

edit: I uploaded this app to the Android Market...when I try to install on the troubled phones, I get an alert saying "Package file was signed incorrectly". 编辑:我将此应用程序上传到Android电子市场...当我尝试在有问题的手机上安装时,我收到一条警告说“包文件签名不正确”。 On the other phones, it downloads and installs just fine. 在其他手机上,它下载和安装就好了。

问题是我正在更新最初通过adb安装的应用程序,而不是通过市场。

If you are trying to download an apk than install it programmatically, be careful to use AsynTask or propery perform threading. 如果您尝试下载apk而不是以编程方式安装它,请小心使用AsynTask或propery执行线程。 I used to face the same error because the activity used to grab an incomplete apk to install it. 我曾经面对同样的错误,因为用于抓取不完整的apk来安装它的活动。

I use AsynTask now. 我现在使用AsynTask。 doInBackground (does the downloading), onPostExecute( adds the pending intent and calls startActivity to open the installation screen). doInBackground(下载),onPostExecute(添加挂起的intent并调用startActivity打开安装屏幕)。

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

相关问题 解析清单时签名的apk解析错误 - signed apk Parse error when parsing manifest Android 安装时解析Manifest - Android Manifest parsing during installation Android安装错误:INSTALL_PARSE_FAILED_MANIFEST_MALFORMED - Android Installation error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED 错误:无法执行应用程序和处理清单。 - Error: Failed to execute app and processing manifest. 错误:“清单中未找到版本代码。” - Error: "Version code not found in manifest." 安装错误:Android 中的 INSTALL_PARSE_FAILED_MANIFEST_MALFORMED - Installation error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED in Android 关于android的Kotlin:找不到主要的合并清单。 导致此错误的原因是什么? - Kotlin on android: Cannot find main merged manifest. What is causing this error? Android分析错误安装错误:INSTALL_PARSE_FAILED_MANIFEST_MALFORMED(由于软件包名称中使用大写字母) - Android parse error Installation error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED (because of Capital letters in package name) Android安装错误:INSTALL_PARSE_FAILED_MANIFEST_MALFORMED“错误13” - Android Installation error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED “error 13” 安装错误:INSTALL_PARSE_FAILED_MANIFEST_MALFORMED如何解决? - Installation error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED how to fix?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM