你上传了一个没有设置’android:exported’属性的APK或Android App Bundle。

huangapple go评论84阅读模式
英文:

You uploaded an APK or Android App Bundle without the 'android:exported' property set

问题

以下是您的AndroidManifest中需要翻译的部分:

> You uploaded an APK or Android App Bundle without the 'android:exported' property set.

Merge Errors
> Error: android:exported needs to be explicitly specified for element <activity#com.onesignal.NotificationOpenedActivityHMS>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 68 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.FCMBroadcastReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 48 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.BootUpReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 99 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.UpgradeReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 105

请注意,上述内容是关于Android应用程序升级时遇到的错误消息和问题的描述。如果您需要进一步的帮助或解决方案,请告诉我。

英文:

just having a freakout moment while upgrading my app from android api 30 to 33, when i upload it on play console i am getting the error which says

> You uploaded an APK or Android App Bundle without the 'android:exported' property set.

even when i have set the 'android:exported' property. but it still shows the same error.

Merge Errors
> Error: android:exported needs to be explicitly specified for element <activity#com.onesignal.NotificationOpenedActivityHMS>. Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 68 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.FCMBroadcastReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 48 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.BootUpReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 99 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.UpgradeReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. CamScanner.app main manifest (this file), line 105

here is my androidmanifest code:

&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;
&lt;manifest xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
    xmlns:tools=&quot;http://schemas.android.com/tools&quot;
    package=&quot;com.scanit.camscanner&quot;&gt;
    &lt;uses-permission android:name=&quot;android.permission.INTERNET&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.ACCESS_NETWORK_STATE&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.ACCESS_WIFI_STATE&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.CAMERA&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.READ_EXTERNAL_STORAGE&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.WRITE_EXTERNAL_STORAGE&quot; /&gt;
    &lt;uses-feature
        android:name=&quot;android.hardware.camera&quot;
        android:required=&quot;true&quot; /&gt;
    &lt;uses-feature
        android:name=&quot;android.hardware.camera.autofocus&quot;
        android:required=&quot;false&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.WAKE_LOCK&quot; /&gt;
    &lt;uses-permission android:name=&quot;android.permission.RECEIVE_BOOT_COMPLETED&quot; /&gt;
    &lt;uses-permission android:name=&quot;com.android.vending.BILLING&quot; /&gt;
    &lt;application
        android:name=&quot;com.scanit.camscanner.MyApp&quot;
        android:allowBackup=&quot;true&quot;
        android:debuggable=&quot;true&quot;
        android:hardwareAccelerated=&quot;true&quot;
        android:icon=&quot;@mipmap/ic_launcher&quot;
        android:label=&quot;@string/app_name&quot;
        android:largeHeap=&quot;true&quot;
        android:networkSecurityConfig=&quot;@xml/network_security_config&quot;
        android:requestLegacyExternalStorage=&quot;true&quot;
        android:roundIcon=&quot;@mipmap/ic_launcher_round&quot;
        android:supportsRtl=&quot;true&quot;
        android:theme=&quot;@style/Theme.CamScanner&quot;
        android:usesCleartextTraffic=&quot;true&quot;
        tools:ignore=&quot;HardcodedDebugMode&quot;&gt;
        &lt;provider
            android:name=&quot;androidx.core.content.FileProvider&quot;
            android:authorities=&quot;${applicationId}.provider&quot;
            android:exported=&quot;false&quot;
            android:grantUriPermissions=&quot;true&quot;
            tools:replace=&quot;android:authorities&quot;&gt;
            &lt;meta-data
                android:name=&quot;android.support.FILE_PROVIDER_PATHS&quot;
                android:resource=&quot;@xml/provider_paths&quot;
                tools:replace=&quot;android:resource&quot;/&gt;
        &lt;/provider&gt;

        &lt;activity android:name=&quot;com.scanit.camscanner.activity.BaseActivity&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.SplashActivity&quot;
            android:screenOrientation=&quot;portrait&quot;
            android:exported=&quot;true&quot;&gt;
            &lt;intent-filter&gt;
                &lt;action android:name=&quot;android.intent.action.MAIN&quot;/&gt;
                &lt;category android:name=&quot;android.intent.category.LAUNCHER&quot;/&gt;
            &lt;/intent-filter&gt;
        &lt;/activity&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.MainActivity&quot;
            android:screenOrientation=&quot;portrait&quot;
            android:windowSoftInputMode=&quot;adjustPan&quot; /&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.ScannerActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.yalantis.ucrop.UCropActivity&quot;
            android:theme=&quot;@style/uCropStyle&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.IDCardPreviewActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.CropDocumentActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.CurrentFilterActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.SavedDocumentActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.DocumentEditorActivity&quot;
            android:screenOrientation=&quot;portrait&quot;
            android:windowSoftInputMode=&quot;adjustNothing&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.SavedEditDocumentActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.SavedDocumentPreviewActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.NoteActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.ImageToTextActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.GroupDocumentActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.PDFViewerActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.QRGenerateActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.QRReaderActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;activity
            android:name=&quot;com.scanit.camscanner.activity.PrivacyPolicyActivity&quot;
            android:screenOrientation=&quot;portrait&quot;/&gt;
        &lt;meta-data
            android:name=&quot;com.google.android.gms.vision.DEPENDENCIES&quot;
            android:value=&quot;ocr&quot;/&gt;
        &lt;meta-data
            android:name=&quot;com.google.android.gms.ads.APPLICATION_ID&quot;
            android:value=&quot;@string/admob_app_id&quot;/&gt;
    &lt;/application&gt;
&lt;/manifest&gt;

答案1

得分: 0

As for the new Android version, you need to set android:exported for each activity, service, and receiver in the manifest file. In your file, I am able to see android:exported for a few activities only, not all. So kindly consider these two points to fix your issue:

  1. 设置 android:exported 给每个活动、服务和接收器在你的清单中。
  2. 错误你得到的是针对其他活动、服务和接收器的,这些不是你的代码的一部分,而是某个库的一部分。要么升级你的库到最新版本,如果它们已经添加了对新Android版本的支持,要么在你的清单中重新注册这些活动、服务或接收器,带上 android:exported 标签。
英文:

As for new android version , you need to set android:exported for each activity , service and receiver in manifest file . In you file , I am able to see android:exported for a few activities only not all .. So kindly consider 2 points here which can fix your issue

  1. Set android:exported to each activity , service and receiver in your manifest
  2. Errors you are getting for other activity , service and receiver which is part of some library and not your code so either upgrade your library to latest version if they have added support for new android version or re-register those activity , service or receiver in your manifest with android:exported tag

huangapple
  • 本文由 发表于 2023年5月7日 18:44:54
  • 转载请务必保留本文链接:https://go.coder-hub.com/76193427.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定