贝宝 Android INSTALL_PARSE_FAILED_MANIFEST_MALFORMED
我正在尝试在我的应用程序中实现 paypal 沙箱,我已按照 中的每个步骤进行操作https://developer.paypal.com/sdk/in-app/android/ ,但是在导入所有内容之后,当我尝试启动我的应用程序时,出现以下错误:
Installation did not succeed.
The application could not be installed: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED
List of apks:
[0] '/Users/xxx/Desktop/Work/shop_java/app/build/outputs/apk/debug/app-debug.apk'
Installation failed due to: 'INSTALL_PARSE_FAILED_MANIFEST_MALFORMED: Failed parse during installPackageLI: /data/app/vmdl695433300.tmp/base.apk (at Binary XML file line #63): com.paypal.pyplcheckout.home.view.activities.PYPLInitiateCheckoutActivity: Targeting S+ (version 31 and above) requires that an explicit value for android:exported be defined when intent filters are present'
我不太明白为什么这是, 我的Android清单是:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.example.xxx">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:fullBackupContent="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:networkSecurityConfig="@xml/network_security_config"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:dataExtractionRules="@xml/data_extraction_rules">
<activity android:name=".ProductActivity"/>
<activity android:name=".promotion.PromotionItemActivity"
/>
<activity
android:name=".MainActivity"
android:exported="true"
android:launchMode="singleTask"
android:hardwareAccelerated="true"
tools:node="merge">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
但是它失败了,我尝试重建,尝试清理,使缓存无效,gradle运行正常,但是当我尝试运行时它说这个,有什么解决方案吗?
I am trying to implement paypal sandbox into my application, i've followed every steps from the https://developer.paypal.com/sdk/in-app/android/ , however after importing everything and when i am trying to start my application i get the following error:
Installation did not succeed.
The application could not be installed: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED
List of apks:
[0] '/Users/xxx/Desktop/Work/shop_java/app/build/outputs/apk/debug/app-debug.apk'
Installation failed due to: 'INSTALL_PARSE_FAILED_MANIFEST_MALFORMED: Failed parse during installPackageLI: /data/app/vmdl695433300.tmp/base.apk (at Binary XML file line #63): com.paypal.pyplcheckout.home.view.activities.PYPLInitiateCheckoutActivity: Targeting S+ (version 31 and above) requires that an explicit value for android:exported be defined when intent filters are present'
And i don't quite understand why it is,
my Android manifest is:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.example.xxx">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:fullBackupContent="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:networkSecurityConfig="@xml/network_security_config"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:dataExtractionRules="@xml/data_extraction_rules">
<activity android:name=".ProductActivity"/>
<activity android:name=".promotion.PromotionItemActivity"
/>
<activity
android:name=".MainActivity"
android:exported="true"
android:launchMode="singleTask"
android:hardwareAccelerated="true"
tools:node="merge">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
However it fails, i tried to rebuild, tried to clean, invalidate caches, gradle runs ok, but when i try to run it says this, any solutions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试更新build.gradle中的库,现在最新版本是0.6.1。
实现 'com.paypal.checkout:android-sdk:0.6.1'
Try to update the Library in build.gradle now the last version is 0.6.1.
implementation 'com.paypal.checkout:android-sdk:0.6.1'