notifee icon indicating copy to clipboard operation
notifee copied to clipboard

How to remove USE_FULL_SCREEN_INTENT?

Open ezequielobreque opened this issue 10 months ago • 21 comments

Hello! I recently uploaded a version of my application that uses notifee to the Play Store and the Android people made me notice that I was using USE_FULL_SCREEN_INTENT, and that I had until May 31 to solve it. Notice that notifee is adding these permissions to the intermediate files. Is there a way to remove this permission that I really don't think I'm using?

notifee 7.8.2

ezequielobreque avatar Apr 09 '24 14:04 ezequielobreque

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

RohanRajGautam avatar Apr 11 '24 18:04 RohanRajGautam

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

Will notifee work as expected If I remove the permission manually?

murat-aksoy avatar May 03 '24 06:05 murat-aksoy

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

I tried this, but it still seems to show up in the generated Manifest. I would have expected that the project manifest would be leading.

sboo avatar May 05 '24 10:05 sboo

I am also experiencing the same issue with my notifee configuration. I am not using asForgroundService and the category is Message. However, I can still see the USE_FULL_SCREEN_INTENT permission in the merged Manifest file.

 await notifee
            .displayNotification({
                id: messageId,
                title: title,
                body: body,
                data: {
                    deepLink: deepLink,
                },
                android: {
                    channelId: pushNotificationChannels.id,
                    groupSummary: true,
                    smallIcon: smallIcon ? smallIcon : 'ic_notification',
                    timestamp: Date.now() - 480000,
                    showTimestamp: true,
                    showChronometer: true,
                    // pressAction is needed if you want the notification to open the app when pressed
                    pressAction: {
                        id: 'default',
                    },
                    category: AndroidCategory.MESSAGE,
                    asForegroundService: false,
                },
                ios: {
                    critical: true,
                    sound: 'default',
                    // iOS > 12
                    // play at 90% sound volume
                    criticalVolume: 0.9,
                },
            })
            .catch((e) => {
                console.log(
                    'Error in pushNotificationController notifee.displayNotification',
                    e,
                );
            });

Please let me know how to remove the USE_FULL_SCREEN_INTENT permission, and if I remove it manually, will it affect the functionality of notifee.

Muha-coinmotion avatar May 16 '24 14:05 Muha-coinmotion

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

Confirming that this worked, android/app/build/outputs/logs/manifest-merger-release-report.txt shows that the USE_FULL_SCREEN_INTENT is REJECTED

Will need to test on Android 14 and Android 12 or under to confirm this causes no actual issues.

taylorkline avatar May 23 '24 20:05 taylorkline

I tested on Android 14 and foreground service works.

radko93 avatar May 24 '24 09:05 radko93

Thanks @taylorkline @RohanRajGautam you saved us. @mikehardy will this library be updated to handle this change?

walterholohan avatar Jun 02 '24 11:06 walterholohan

In my case I use only one function of library

 notifee.getBadgeCount().then(count => {
      if (count) {
        notifee.setBadgeCount(0)
      }
 }

and all application not approve because use this USE_FULL_SCREEN_INTENT permission :-)

anatooly avatar Jun 03 '24 07:06 anatooly

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

Confirming that this worked, android/app/build/outputs/logs/manifest-merger-release-report.txt shows that the USE_FULL_SCREEN_INTENT is REJECTED

Will need to test on Android 14 and Android 12 or under to confirm this causes no actual issues.

Hello, I did the same but I do not see that permission is rejected in the manifest log. When I upload my .aab file to the store, the warning still exists.

Could It be cache?

Thanks.

murat-aksoy avatar Jun 03 '24 08:06 murat-aksoy

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

Confirming that this worked, android/app/build/outputs/logs/manifest-merger-release-report.txt shows that the USE_FULL_SCREEN_INTENT is REJECTED

Will need to test on Android 14 and Android 12 or under to confirm this causes no actual issues.

I also did the same but google play store still rejecting my app due to use of Full-screen intent permission.

Screenshot 2024-06-03 at 2 54 48 PM

My android/app/build/outputs/logs/manifest-merger-release-report.txt looks like

UmRAsLoE

MohsinAtArbisoft avatar Jun 03 '24 09:06 MohsinAtArbisoft

Faced a similar issue with Play Store complaining about FULL_SCREEN_INTENT permission, and removing my app from the Play Store. So, I removed the permission manually from AndroidManifest.xml, and it works now.

<manifest
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools" <= ADD THIS LINE
  package="com.something">
<uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove" />

source: https://stackoverflow.com/questions/49025927/react-native-remove-default-android-permissions

Confirming that this worked, android/app/build/outputs/logs/manifest-merger-release-report.txt shows that the USE_FULL_SCREEN_INTENT is REJECTED Will need to test on Android 14 and Android 12 or under to confirm this causes no actual issues.

I also did the same but google play store still rejecting my app due to use of Full-screen intent permission.

Screenshot 2024-06-03 at 2 54 48 PM My `android/app/build/outputs/logs/manifest-merger-release-report.txt` looks like UmRAsLoE

I can confirm that https://github.com/invertase/notifee/issues/1027#issuecomment-2050295835 works as expected. You can see the merged manifest in android/app/build/intermediates/merged_manifest.

The message on the Play Store is super confusing. If you click into it, you'll see that the declaration is for existing bundles, not the new bundle you're trying to upload. However, you can't proceed with the new upload until the declaration is made.

mars-lan avatar Jun 03 '24 13:06 mars-lan

This works. Thank you all.

foreteesCaddie1 avatar Jun 04 '24 14:06 foreteesCaddie1

If anyone is wondering how to do it in Expo, you can simply set in android object: blockedPermissions: ['android.permission.USE_FULL_SCREEN_INTENT'],

List of permissions to block in the final AndroidManifest.xml. This is useful for removing permissions that are added by native package AndroidManifest.xml files which are merged into the final manifest. Internally this feature uses the tools:node="remove" XML attribute to remove permissions.

AronBe avatar Jun 05 '24 05:06 AronBe

If anyone is wondering how to do it in Expo, you can simply set in android object: blockedPermissions: ['android.permission.USE_FULL_SCREEN_INTENT'],

List of permissions to block in the final AndroidManifest.xml. This is useful for removing permissions that are added by native package AndroidManifest.xml files which are merged into the final manifest. Internally this feature uses the tools:node="remove" XML attribute to remove permissions.

I added to the app.json the android.permission.USE_FULL_SCREEN_INTENT ,but when I uploaded de aab file, it stills shows the android.permission.USE_FULL_SCREEN_INTENT permission on the list of permissions. Strange.

Do I need anything else? prebuild?

EDIT: yep, a prebuild is needed

fmendez89 avatar Jun 05 '24 10:06 fmendez89

Will this permission be removed from the notifee manifest now? It does not seem to be required for it to function?

pke avatar Jun 20 '24 21:06 pke

If anyone is wondering how to do it in Expo, you can simply set in android object: blockedPermissions: ['android.permission.USE_FULL_SCREEN_INTENT'],

List of permissions to block in the final AndroidManifest.xml. This is useful for removing permissions that are added by native package AndroidManifest.xml files which are merged into the final manifest. Internally this feature uses the tools:node="remove" XML attribute to remove permissions.

I added to the app.json the android.permission.USE_FULL_SCREEN_INTENT ,but when I uploaded de aab file, it stills shows the android.permission.USE_FULL_SCREEN_INTENT permission on the list of permissions. Strange.

Do I need anything else? prebuild?

EDIT: yep, a prebuild is needed

Did you solved? the aab bundle still has permission.. file: manifest-merger-release-report.txt has follow lines

ADDED from project/android/app/src/main/AndroidManifest.xml:11:3-98
REJECTED from [app.notifee:core:202108261754] ~/.gradle/caches/transforms-4/c28e4249bb622db06eef1ba986aafe27/transformed/jetified-core-202108261754/AndroidManifest.xml:16:5-81
	tools:node
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:77-96
	android:name
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:20-76

even if set the below manifest.xml

<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">
...
  <uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove"/>
...

eyu0415 avatar Jun 21 '24 16:06 eyu0415

If anyone is wondering how to do it in Expo, you can simply set in android object: blockedPermissions: ['android.permission.USE_FULL_SCREEN_INTENT'],

List of permissions to block in the final AndroidManifest.xml. This is useful for removing permissions that are added by native package AndroidManifest.xml files which are merged into the final manifest. Internally this feature uses the tools:node="remove" XML attribute to remove permissions.

I added to the app.json the android.permission.USE_FULL_SCREEN_INTENT ,but when I uploaded de aab file, it stills shows the android.permission.USE_FULL_SCREEN_INTENT permission on the list of permissions. Strange. Do I need anything else? prebuild? EDIT: yep, a prebuild is needed

Did you solved? the aab bundle still has permission.. file: manifest-merger-release-report.txt has follow lines

ADDED from project/android/app/src/main/AndroidManifest.xml:11:3-98
REJECTED from [app.notifee:core:202108261754] ~/.gradle/caches/transforms-4/c28e4249bb622db06eef1ba986aafe27/transformed/jetified-core-202108261754/AndroidManifest.xml:16:5-81
	tools:node
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:77-96
	android:name
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:20-76

even if set the below manifest.xml

<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">
...
  <uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove"/>
...

When I run the expo prebuild it removed the permission from the manifest and when uploaded the aab, it showed that the permission was effectively removed in the Play Console.

fmendez89 avatar Jun 21 '24 18:06 fmendez89

If anyone is wondering how to do it in Expo, you can simply set in android object: blockedPermissions: ['android.permission.USE_FULL_SCREEN_INTENT'],

List of permissions to block in the final AndroidManifest.xml. This is useful for removing permissions that are added by native package AndroidManifest.xml files which are merged into the final manifest. Internally this feature uses the tools:node="remove" XML attribute to remove permissions.

I added to the app.json the android.permission.USE_FULL_SCREEN_INTENT ,but when I uploaded de aab file, it stills shows the android.permission.USE_FULL_SCREEN_INTENT permission on the list of permissions. Strange. Do I need anything else? prebuild? EDIT: yep, a prebuild is needed

Did you solved? the aab bundle still has permission.. file: manifest-merger-release-report.txt has follow lines

ADDED from project/android/app/src/main/AndroidManifest.xml:11:3-98
REJECTED from [app.notifee:core:202108261754] ~/.gradle/caches/transforms-4/c28e4249bb622db06eef1ba986aafe27/transformed/jetified-core-202108261754/AndroidManifest.xml:16:5-81
	tools:node
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:77-96
	android:name
		ADDED from project/android/app/src/main/AndroidManifest.xml:11:20-76

even if set the below manifest.xml

<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">
...
  <uses-permission android:name="android.permission.USE_FULL_SCREEN_INTENT" tools:node="remove"/>
...

This logs looks correct, the final androidManifest will not have USE_FULL_SCREEN_INTENT. To check this try to upload bundle to the Play Market and go thought bundle details (App bundle explorer). Here you can find all permissions that you are using in your app.

FURY-PERSON avatar Jun 21 '24 22:06 FURY-PERSON

Hello 👋, to help manage issues we automatically close stale issues.

This issue has been automatically marked as stale because it has not had activity for quite some time.Has this issue been fixed, or does it still require attention?

This issue will be closed in 15 days if no further activity occurs.

Thank you for your contributions.

github-actions[bot] avatar Jul 19 '24 22:07 github-actions[bot]

This appears to be work-around-able but not fixed.

taylorkline avatar Jul 22 '24 16:07 taylorkline

Hi, having the same issue, can someone confirm if the library works fine after we remove the permission?

gagtic avatar Jul 31 '24 10:07 gagtic

@gagtic the library works fine unless you have full screen notifications. (Alarm, calls etc)

MohsinAtArbisoft avatar Jul 31 '24 13:07 MohsinAtArbisoft

@gagtic the library works fine unless you have full screen notifications. (Alarm, calls etc)

Confirmed on our end as well, we tested iOS and Android both with foreground and background notifications, no issues.

taylorkline avatar Jul 31 '24 16:07 taylorkline

What is s fullscreen notification? How is it triggered?

pke avatar Jul 31 '24 16:07 pke

What is s fullscreen notification? How is it triggered?

Full Screen Notifications are notifications that cover the whole screen. Your app might need to display an urgent, time-sensitive message, such as an incoming phone call or a ringing alarm. In these situations, you can associate a full-screen intent with your notification.

When the notification is invoked, users see one of the following, depending on the device's lock status:

  • If the user's device is locked, a full-screen activity appears, covering the lockscreen.
  • If the user's device is unlocked, the notification appears in an expanded form that includes options for handling or dismissing the notification.

MohsinAtArbisoft avatar Aug 01 '24 06:08 MohsinAtArbisoft

Hello 👋, to help manage issues we automatically close stale issues.

This issue has been automatically marked as stale because it has not had activity for quite some time.Has this issue been fixed, or does it still require attention?

This issue will be closed in 15 days if no further activity occurs.

Thank you for your contributions.

github-actions[bot] avatar Aug 29 '24 07:08 github-actions[bot]

This issue still exists. Will try the workaround

hackily avatar Aug 30 '24 15:08 hackily

This works for me "android": { "blockedPermissions": [ "android.permission.USE_FULL_SCREEN_INTENT" ] },

hochonin93 avatar Sep 01 '24 03:09 hochonin93

This is working. Those who are struggling might be adding it to the wrong manifest file. It has to be added in the main Manifest file i.e. android/app/src/main/AndroidManifest.xml

lakshayasachdeva avatar Sep 12 '24 05:09 lakshayasachdeva