-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Fix for indirect notification activity start (trampoline) from blocked #2352
base: master
Are you sure you want to change the base?
Conversation
Any process on this PR? I am currently facing with this issue |
@ChrisNg02655332 if you Need urgently, use my fork package in meantime waiting for merge the pr |
Still dont work it still says Indirect notification activity start (trampoline) |
This is also not working for me. It still gives me the same error message: "Indirect notification activity start (trampoline) from app blocked." 🥲 |
@kartik8Zapkey have you tried changes in my fork? |
Yes i tried your fork , but still dont work. is anyone here for whom it is working ?? |
@fcaldarelli |
how to pull this commit into my project |
We are blocked due to this error can someone please share any solutions |
This branch works, but the repo looks abandoned. I don't think it will be merged in soon. I've created a pacth (usabale with patch-packe):
|
@fcaldarelli |
@Ben8823 have you tried to clean e rebuild the project? |
@fcaldarelli yes I did run a gradle clean |
@Ben8823 have you tried to link my repo as library: https://github.com/fcaldarelli/react-native-push-notification ? |
@fcaldarelli yes I'm using this in my package.json: |
@fcaldarelli it turned out that the |
This worked for me, notifications were showing up but clicking them doesn't open the app before. |
@mikmedina avoid to use patch in node_modules, because it does not works in CI/CD and everytime you need to download node_modules. |
facing the same issue, I tried to exactly like Ben8823 "react-native-push-notification": "github:fcaldarelli/react-native-push-notification#c625b16e419631bc5c40d1df0919fb91162ac57", ./gradlew clean, verify dependencies to see if any other package would force a different version of firebase-messaging. But no luck, still having that trampoline issue. |
after deep investigation, I have no clue why updating firebase would solve the issue. I can only intuit may be the target version of android that was used to validate it is working or not was under the threashold of the trampoline feature. On paper, when reading what this feature is, it should not be possible if you target an modern SDK that fall under the trampoline feature, to invokeApp or deeplink from the onAction in background task. That is the whole purpose of this feature -> forbid us to do so. So google is asking that instead of doing trampoline (that's the way they call this action of defering the invokeApp via a background task, to directly configure the action to open a deepLink, bypassing the middleman, and therefore making the action more responsive. |
@fcaldarelli (https://github.com/fcaldarelli) Not working for me .Still have the issue. My app is not opening notification actions above android 12,12+ devices In log cat "Indirect notification activity start (trampoline) from com.app.tb blocked" java.lang.RuntimeException: Unable to start receiver com.dieam.reactnativepushnotification.modules.RNPushNotificationActions: java.lang.SecurityException Background activity launch blocked [callingPackage: com.app.tb; callingUid: 10208; appSwitchState: 2; callingUidHasAnyVisibleWindow: false; callingUidProcState: RECEIVER; isCallingUidPersistentSystemProcess: false; balAllowedByPiSender: BackgroundStartPrivileges[allowsBackgroundActivityStarts=false, allowsBackgroundForegroundServiceStarts=true, originatingToken=null]; realCallingPackage: com.app.tb; realCallingUid: 10208; realCallingUidHasAnyVisibleWindow: false; realCallingUidProcState: RECEIVER; isRealCallingUidPersistentSystemProcess: false; originatingPendingIntent: null; backgroundStartPrivileges: BackgroundStartPrivileges[allowsBackgroundActivityStarts=false, allowsBackgroundForegroundServiceStarts=false, originatingToken=null]; intent: Intent { flg=0x10000000 cmp=com.app.tb/.MainActivity (has extras) }; callerApp: ProcessRecord{c36be3 26555:com.app.tb/u0a208}; inVisibleTask: false] { |
@@ -60,5 +60,6 @@ dependencies { | |||
implementation "$appCompatLibName:$supportLibVersion" | |||
implementation 'com.facebook.react:react-native:+' | |||
implementation 'me.leolin:ShortcutBadger:1.1.22@aar' | |||
implementation "com.google.firebase:firebase-messaging:${safeExtGet('firebaseMessagingVersion', '21.1.0')}" | |||
implementation "com.google.firebase:firebase-messaging:${safeExtGet('firebaseMessagingVersion', '23.1.2')}" | |||
implementation "com.google.firebase:firebase-iid:21.1.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line was not needed for me
RN 71
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding firebaseMessagingVersion = '23.1.2'
to ext
on android/build.gradle
Even 23.4.1
works for me
Avoids having this change
@fcaldarelli Hello, can anyone please help me? I'm getting an error on Android 12+ apps when clicking actions (accept, reject): "Indirect notification activity start (trampoline) from com.pickyassist.tb blocked" Here is my package.json: "dependencies": { There is no issue if I click on the notification, but when clicking on the notification action, I get this trampoline issue. How i resolve this issue ? My android/app/build.gradle
} i can see the changes on node_modules/react-native-push-notification/android/build.gradle
} |
No description provided.