react-native-firebase icon indicating copy to clipboard operation
react-native-firebase copied to clipboard

Notification not displaying when app is in quit state (swiped away from recents) in android

Open RejoV opened this issue 2 years ago • 7 comments

Following are the dependencies used in my project: "@react-native-firebase/app": "14.5.0", "@react-native-firebase/messaging": "14.5.0", "react": "17.0.2", "react-native": "0.67.2", I've used the following code as mentioned in documentation in index.js messaging().setBackgroundMessageHandler(async remoteMessage => { console.log('Message handled in the background!', remoteMessage); });

When app is in foreground and background it works fine. Issue arises when app is swiped away from recent apps. I've even removed battery optimisation and gave permission to run in background from settings. Thanks in advance

RejoV avatar Feb 18 '22 09:02 RejoV

Hi there - I think this is the case where you have told the operating system "stop running this app", and basically it believed you. You haven't mentioned anything about the device in question or the JSON you are sending (remove the device token of course but please post the raw JSON you are sending to the FCM REST API end point so no one has to make assumptions...) or what you see in adb logcat (unfiltered) when the device receives the FCM (https://stackoverflow.com/help/how-to-ask)

mikehardy avatar Feb 18 '22 12:02 mikehardy

Hi, I've sent fcm notification via firebase console. {"displayName":"Test","state":"RUNNING","onStart":{},"notificationOptions":{"messageText":"Testing","messageTitle":"Test","hasSound":false,"imageUrl":"","expiryTime":"2419200s","registrationIds":["xxxx"]},"dataBundle":{}} while running adb logcat notification logs are not coming when app is in swiped away state, but notification logs are being shown when the app is in foreground or background. Thanks you in advance.

RejoV avatar Feb 21 '22 05:02 RejoV

I can also reproduce this issue. After the app is completely closed and wait for few minutes .setBackgroundMessageHandler is not triggered when the notification is received. This only happens on Android 11 and 12. I've tested on Android 7 device and worked just fine.

jinshin1013 avatar Feb 23 '22 00:02 jinshin1013

https://github.com/invertase/react-native-firebase/issues/6085#issuecomment-1044468577

adb logcat results would be quite interesting. Also note this could be device-specific: https://dontkillmyapp.com/ - so any details from your testing should be as precise as you can be about controlling the experiment / explaining experimental conditions

mikehardy avatar Feb 23 '22 00:02 mikehardy

I found something interesting. I'm not sure if this is a known issue but whenever I force stop the app, then the app will not receive any notification. Is this because the background callback handler set by setBackgroundMessageHandler is no longer active?

@mikehardy I'm attaching 2 separate logs:

  1. App is closed by Force Stop in the Settings and logs after pushing a notification
  2. App is closed by a normal swipe up and logs after pushing a notification

You can see that there are some logs on RNFirebaseMsgReceiver and FirebaseMessaging when the app is closed normally but no logs when it's force closed.

App Force Close and ADB logs after pushing a notification
2022-03-29 10:11:10.666 -0400  3392  3635 D BtGatt.GattService: onScanResult to scannerId: 6- eventType=0x1b, addressType=1, address=70ED35_7, primaryPhy=1, secondaryPhy=0, advertisingSid=0xff, txPower=127, rssi=-74, periodicAdvInt=0x02022-03-29 10:11:12.055 -0400  4105  4918 I SDHMS:C : -99 > surface_temperature_0
2022-03-29 10:11:12.058 -0400  4105  4918 I SDHMS:C : writeSysfs:: path() : /sys/class/audio/amp/surface_temperature_0 exist() : false canWrite() : false2022-03-29 10:11:12.058 -0400  4105  4918 I SDHMS:C : -99 > surface_temperature_1
2022-03-29 10:11:12.058 -0400  4105  4918 I SDHMS:C : writeSysfs:: path() : /sys/class/audio/amp/surface_temperature_1 exist() : false canWrite() : false
2022-03-29 10:11:12.059 -0400  4105  4918 I SDHMS:C : SIOP:: AP:379(442,110) BAT:356(356,0) USB:378(378,0) CHG:403(403,0) PA:421(421,0) WIFI:387(387,0) BLK:0(0,0) SUBBAT:0(0,0) LRP:362(362,0) LRF:359(359) LRB:362(362)2022-03-29 10:11:12.063 -0400  1112  4232 D SemContextService: lock : registerCallback2022-03-29 10:11:12.065 -0400  1112  4232 W CAE     : registerCallback(ContextAwareService.java:192) - [regi 01] Mutex is locked for TEST_FLAT_MOTION
2022-03-29 10:11:12.065 -0400  1112  4232 W CAE     : registerCallback(ContextAwareService.java:199) - [regi 04]  com.samsung.android.contextaware.ContextAwareManager$CaListenerDelegate@9be7cdd
2022-03-29 10:11:12.065 -0400  1112  1112 D SemWifiP2pService: GopsReceiver : received : com.samsung.intent.action.CHECK_SIOP_LEVEL2022-03-29 10:11:12.065 -0400  1112  1112 I SemWifiP2pService: siop_level = 0
2022-03-29 10:11:12.065 -0400  1112  4232 W CAE     : getListener(ListenerListManager.java:127) - [getListener1]  com.samsung.android.contextaware.ContextAwareManager$CaListenerDelegate@9be7cdd2022-03-29 10:11:12.066 -0400  1112  4232 W CAE     : getListener(ListenerListManager.java:128) - [getListener2]  com.samsung.android.contextaware.manager.ContextAwareService$Listener@2f2c8b42022-03-29 10:11:12.067 -0400  1112  4232 V CAE     : start(ContextProvider.java:128)
2022-03-29 10:11:12.067 -0400  1112  4232 V CAE     : clear(TestFlatMotionRunner.java:126)
2022-03-29 10:11:12.067 -0400  1112  1112 D SemWifiP2pService: GopsReceiver : received : com.samsung.intent.action.CHECK_SIOP_LEVEL time : 2ms2022-03-29 10:11:12.068 -0400  1112  4232 V CAE     : enable(TestFlatMotionRunner.java:102)
2022-03-29 10:11:12.068 -0400  9243  9331 I SystemBroadcastReceiver: [#CMH#] onReceive completed :  02022-03-29 10:11:12.068 -0400  1112  4232 I CAE     : sendCmdToSensorHub(SensorHubCommManager.java:156) - -79, 23, 0, 0,
2022-03-29 10:11:12.068 -0400  9243  9243 I PolicyManager: [#CMH#] onReceive action = EVENT_SIOP
2022-03-29 10:11:12.069 -0400  1112  1736 D SensorService: setSContextDataLocked ints length 2 , byte length 42022-03-29 10:11:12.069 -0400  1112  1736 D SensorService: setSContextDataLocked 17b1
2022-03-29 10:11:12.069 -0400   852   852 I sensors-hal: inject_sensor_data:379, handle 1501 send inject
2022-03-29 10:11:12.069 -0400   852   852 I sensors-hal: sendContextData:251, sensor hal 4, (0xb1, 0x17, 0x0, 0x0)2022-03-29 10:11:12.069 -0400   852   852 I sensors-hal: sendContextData:304, enable:177, handle:8, algo:16777216
2022-03-29 10:11:12.070 -0400   852   852 E sensors-hal: is_restrict_mode:137, fread fail
2022-03-29 10:11:12.070 -0400   852   852 I sensors-hal: sendContextData:107, device_position 4
2022-03-29 10:11:12.070 -0400   852   852 I sensors-hal: get_qmi_debug_flag:241, support_qmi_debug : false2022-03-29 10:11:12.083 -0400   852   852 I sensors-hal: create_sensor_config_request:47, device_position create_sensor_config_request2022-03-29 10:11:12.085 -0400  1112  4232 D CAE     : getFaultDetectionResult(TestFlatMotionRunner.java:139) - true2022-03-29 10:11:12.086 -0400  1112  4232 I CAE     : notifyCmdProcessResultObserver(ContextProvider.java:627) - CheckResult = 0, Cause = Success2022-03-29 10:11:12.089 -0400  1112  4232 D CAE     : doCommendProcess(ContextAwareService.java:400) - complete notify the operation result.2022-03-29 10:11:12.090 -0400  1112  4232 I CAE     : displayUsedCountForService(ContextAwareService.java:464) - totalCnt = 1, serviceCount = 1, subCollectionCount = 02022-03-29 10:11:12.090 -0400  1112  4232 D CAE     : showListenerList(ContextAwareService.java:329) - ===== Context Aware Service List =====
2022-03-29 10:11:12.090 -0400  1112  4232 I CAE     : showListenerList(ContextAwareService.java:338) - Listener : com.samsung.android.contextaware.manager.ContextAwareService$Listener@2f2c8b4, Service : FREE_FALL_DETECTION(1)
2022-03-29 10:11:12.091 -0400  1112  4232 I CAE     : showListenerList(ContextAwareService.java:338) - Listener : com.samsung.android.contextaware.manager.ContextAwareService$Listener@2f2c8b4, Service : TEST_FLAT_MOTION(1)
2022-03-29 10:11:12.091 -0400  1112  4232 W CAE     : registerCallback(ContextAwareService.java:213) - [regi 02] Mutex is unlocked for TEST_FLAT_MOTION
2022-03-29 10:11:12.091 -0400  1112  4232 E SemContext.CaeProvider: setAttribute() : attribute is null!2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : Outgoing transactions from this process must be FLAG_ONEWAY
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : java.lang.Throwable
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at android.os.BinderProxy.transact(BinderProxy.java:545)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at com.samsung.android.hardware.context.ISemContextCallback$Stub$Proxy.getListenerInfo(ISemContextCallback.java:166)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at com.samsung.android.hardware.context.SemContextService$ListenerManager.notifyListeners(SemContextService.java:1351)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at com.samsung.android.hardware.context.SemContextService.registerCallback(SemContextService.java:278)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at com.samsung.android.hardware.context.ISemContextService$Stub.onTransact(ISemContextService.java:158)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at android.os.Binder.execTransactInternal(Binder.java:1220)
2022-03-29 10:11:12.092 -0400  1112  4232 W Binder  : 	at android.os.Binder.execTransact(Binder.java:1179)2022-03-29 10:11:12.093 -0400  1112  4232 D SemContextService: 	.registerCallback : 2, client=com.sec.android.sdhms.thermal.overheatcontrol.OverheatSensorChecker$TypeSemContext$1@f6dd510
2022-03-29 10:11:12.093 -0400  1112  4232 D SemContextConnectionList: client packageName : com.sec.android.sdhms.thermal.overheatcontrol.OverheatSensorChecker$TypeSemContext$1@f6dd5102022-03-29 10:11:12.093 -0400  1112  4232 D SemContextService: unlock : registerCallback
2022-03-29 10:11:12.101 -0400  1112  2707 D SensorService: Calling batch handle==51 flags=0 rate=200000000 timeout== 0
2022-03-29 10:11:12.102 -0400   852   852 I sensors-hal: set_config:67, sample_period_ns is adjusted to 0 based on min/max delay_ns
2022-03-29 10:11:12.102 -0400   852   852 I sensors-hal: batch:336, android.sensor.light/51, period=200000000, max_latency=0 request completed
2022-03-29 10:11:12.103 -0400   852   852 I sensors-hal: activate:252, android.sensor.light/51 en=12022-03-29 10:11:12.103 -0400   852   852 I sensors-hal: get_qmi_debug_flag:241, support_qmi_debug : false2022-03-29 10:11:12.113 -0400   852   852 I sensors-hal: activate:270, android.sensor.light/51 en=1 completed2022-03-29 10:11:12.116 -0400  1112  2707 D SensorService: Calling batch handle==33554437 flags=0 rate=10000000 timeout== 0
2022-03-29 10:11:12.117 -0400   852   852 D [email protected]: BioSensor_common::setDelay, handle : 5 time : 10000000ns
2022-03-29 10:11:12.117 -0400   852   852 D [email protected]: BioSensor_common::enable, handle : 5, mode : 3, en : 1
2022-03-29 10:11:12.117 -0400   852   852 D [email protected]: BioSensor_common::getEolStatus, eol status : 0
2022-03-29 10:11:12.117 -0400   852   852 D [email protected]: BioSensor_common::pushMode, mode : 3, stack index : 02022-03-29 10:11:12.117 -0400   852   852 D [email protected]: BioSensor_common::sendCommand, send enable command (mode:3)2022-03-29 10:11:12.135 -0400   852 21191 I sensors-hal: handle_indication_realtime:466,  SCHED_FIFO(10) for qmi_cbk2022-03-29 10:11:12.186 -0400   852 21191 I sensors-hal: handle_sns_std_sensor_event:119, [SSC_LIGHT] ambient_light lux: 0, ts=175393066586262022-03-29 10:11:12.187 -0400  1112  2707 D SensorService: Calling activate off 33554437
2022-03-29 10:11:12.188 -0400   852   852 D [email protected]: BioSensor_common::enable, handle : 5, mode : 3, en : 0
2022-03-29 10:11:12.188 -0400   852   852 D [email protected]: BioSensor_common::sendCommand, send disable command2022-03-29 10:11:12.189 -0400   852   852 I flicker_log: flicker deinit2022-03-29 10:11:12.192 -0400  1112  4232 D SensorService: Calling activate off 512022-03-29 10:11:12.192 -0400   852   852 I sensors-hal: activate:252, android.sensor.light/51 en=0
2022-03-29 10:11:12.193 -0400   852   852 I sensors-hal: deactivate:301, disconnect qmi to disable sensor2022-03-29 10:11:12.194 -0400   852   852 I sensors-hal: activate:270, android.sensor.light/51 en=0 completed2022-03-29 10:11:12.201 -0400   852 21187 I sensors-hal: handle_sns_client_event:77, device_position_event: msgid:10252022-03-29 10:11:12.201 -0400   852 21187 I sensors-hal: handle_sns_client_event:96, device_position_event: 3
2022-03-29 10:11:12.203 -0400  1112  1727 D SensorHubManager: onGetSensorHubDataLocked: library(4) = 1, 1, 23, 32022-03-29 10:11:12.204 -0400  1112  1728 D CAE     : onGetSensorHubData(SensorHubParserProvider.java:89) - onGetSensorHubData Event [event buffer len :4], AP_WAKEUP2022-03-29 10:11:12.204 -0400  1112  1728 I CAE     : parse(SensorHubParserProvider.java:190) - buffer size = 42022-03-29 10:11:12.204 -0400  1112  1728 I CAE     : parse(SensorHubParserProvider.java:201) - 1, 1, 23, 3,
2022-03-29 10:11:12.206 -0400  1112  1728 D CAE     : display(ContextProvider.java:375) - ================= TEST_FLAT_MOTION =================
2022-03-29 10:11:12.206 -0400  1112  1728 I CAE     : display(ContextProvider.java:391) - Action=[3]2022-03-29 10:11:12.207 -0400  1112  1725 D SemContextService: Service.updateContext() : service = Device Position2022-03-29 10:11:12.210 -0400  1112  4232 D SemContextService: lock : unregisterCallback2022-03-29 10:11:12.210 -0400  1112  4232 D SemContextService: Service.removeListenerLocked() : listener = com.samsung.android.hardware.context.SemContextService$Listener@e5e5475, service = Device Position, used = 02022-03-29 10:11:12.210 -0400  1112  4232 W CAE     : unregisterCallback(ContextAwareService.java:234) - [unregi 01] Mutex is locked for TEST_FLAT_MOTION
2022-03-29 10:11:12.211 -0400  1112  4232 W CAE     : getListener(ListenerListManager.java:127) - [getListener1]  com.samsung.android.contextaware.ContextAwareManager$CaListenerDelegate@9be7cdd
2022-03-29 10:11:12.211 -0400  1112  4232 W CAE     : getListener(ListenerListManager.java:128) - [getListener2]  com.samsung.android.contextaware.manager.ContextAwareService$Listener@2f2c8b4
2022-03-29 10:11:12.212 -0400  1112  4232 V CAE     : stop(ContextProvider.java:155)2022-03-29 10:11:12.212 -0400  1112  4232 V CAE     : clear(TestFlatMotionRunner.java:126)
2022-03-29 10:11:12.213 -0400  1112  4232 V CAE     : disable(TestFlatMotionRunner.java:115)
2022-03-29 10:11:12.213 -0400  1112  4232 I CAE     : sendCmdToSensorHub(SensorHubCommManager.java:156) - -78, 23, 0, 0,
2022-03-29 10:11:12.214 -0400  1112  1736 D SensorService: setSContextDataLocked ints length 2 , byte length 42022-03-29 10:11:12.214 -0400  1112  1736 D SensorService: setSContextDataLocked 17b2
2022-03-29 10:11:12.214 -0400   852   852 I sensors-hal: inject_sensor_data:379, handle 1501 send inject2022-03-29 10:11:12.214 -0400   852   852 I sensors-hal: sendContextData:251, sensor hal 4, (0xb2, 0x17, 0x0, 0x0)
2022-03-29 10:11:12.214 -0400   852   852 I sensors-hal: sendContextData:304, enable:178, handle:8, algo:167774722022-03-29 10:11:12.215 -0400   852   852 I sensors-hal: sendContextData:107, device_position 4
2022-03-29 10:11:12.218 -0400   852   852 I sensors-hal: deactivate:301, disconnect qmi to disable sensor2022-03-29 10:11:12.219 -0400  1112  4232 D CAE     : getFaultDetectionResult(TestFlatMotionRunner.java:139) - true
2022-03-29 10:11:12.220 -0400  1112  4232 I CAE     : notifyCmdProcessResultObserver(ContextProvider.java:627) - CheckResult = 0, Cause = Success2022-03-29 10:11:12.221 -0400  1112  4232 D CAE     : doCommendProcess(ContextAwareService.java:400) - complete notify the operation result.
2022-03-29 10:11:12.221 -0400  1112  4232 I CAE     : displayUsedCountForService(ContextAwareService.java:464) - totalCnt = 0, serviceCount = 0, subCollectionCount = 0
2022-03-29 10:11:12.222 -0400  1112  4232 D CAE     : showListenerList(ContextAwareService.java:329) - ===== Context Aware Service List =====
2022-03-29 10:11:12.222 -0400  1112  4232 I CAE     : showListenerList(ContextAwareService.java:338) - Listener : com.samsung.android.contextaware.manager.ContextAwareService$Listener@2f2c8b4, Service : FREE_FALL_DETECTION(1)2022-03-29 10:11:12.222 -0400  1112  4232 W CAE     : unregisterCallback(ContextAwareService.java:255) - [unregi 02] Mutex is unlocked for TEST_FLAT_MOTION
2022-03-29 10:11:12.223 -0400  1112  4232 D SemContextService: 	.unregisterCallback : 1, client=com.sec.android.sdhms.thermal.overheatcontrol.OverheatSensorChecker$TypeSemContext$1@f6dd5102022-03-29 10:11:12.223 -0400  1112  4232 D SemContextService: unlock : unregisterCallback2022-03-29 10:11:12.262 -0400   852 18304 I sensors-hal: handle_sns_client_event:660, [0][15701] accel_sample [-2.015, -9.444,  1.535] 175393738083132022-03-29 10:11:12.425 -0400  1112  1793 D ConnectivityService: reportNetworkActive, notify 0 listeners2022-03-29 10:11:12.440 -0400  2909 23832 D ConnectivityManager: StackLog: [android.net.ConnectivityManager.reportNetworkConnectivity(ConnectivityManager.java:3139)] [aggz.i(:com.google.android.gms@[email protected] (190400-434869283):0)] [aggq.run(:com.google.android.gms@[email protected] (190400-434869283):49)] [wex.c(:com.google.android.gms@[email protected] (190400-434869283):6)] [wex.run(:com.google.android.gms@[email protected] (190400-434869283):7)] [java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)] [java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)] [wkb.run(:com.google.android.gms@[email protected] (190400-434869283):0)] [java.lang.Thread.run(Thread.java:920)]2022-03-29 10:11:12.441 -0400  1112  2707 D SamsungAlarmManager: Cancel Alarm calling from uid:10099 pid :2909 / OP:PendingIntent{3651c7b: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}
2022-03-29 10:11:12.442 -0400  1112  2707 V SamsungAlarmManager: setLocked to kernel - W:17606745 / NW:17564726, now=175395652022-03-29 10:11:12.443 -0400  1112  2707 D SamsungAlarmManager: setExact (T:2/F:33/AC:false) 20220329T103902 now=17539566 - CU:10099/CP:2909/OP:PendingIntent{2dcca98: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}2022-03-29 10:11:12.443 -0400  1112  2707 V SamsungAlarmManager: setLocked to kernel - W:17606745 / NW:17564726, now=175395672022-03-29 10:11:12.450 -0400  2909  2909 W GCM     : broadcast intent callback: result=CANCELLED forIntent { act=com.google.android.c2dm.intent.RECEIVE pkg=io.getamber.app.sandbox (has extras) }2022-03-29 10:11:12.456 -0400  1112  2707 V SamsungAlarmManager: setLocked to kernel - W:18399416 / NW:17564726, now=175395802022-03-29 10:11:12.457 -0400  1112  2707 D SamsungAlarmManager: setExact (T:2/F:33/AC:false) 20220329T101219 now=17539580 - CU:10099/CP:2909/OP:PendingIntent{e1f0557: PendingIntentRecord{42eb6e9 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}
2022-03-29 10:11:12.457 -0400  1112  2707 V SamsungAlarmManager: setLocked to kernel - W:17606745 / NW:17564726, now=175395812022-03-29 10:11:12.546 -0400   852 18288 I sensors-hal: handle_sns_client_event:207, auto_rotation_event_2: mode:255, type:1:0/-2.013,-9.459,1.5182022-03-29 10:11:12.582 -0400  2137  2137 I wpa_supplicant: Heartbeat 17502022-03-29 10:11:13.693 -0400 28777 28777 I ContentCaptureService: unbinding from com.samsung.android.smartsuggestions.extservice.services.ContentCaptureService2022-03-29 10:11:13.702 -0400  1112  1112 I ActivityManager: Changes in 10132 5 to 10, 15 to 0
2022-03-29 10:11:13.703 -0400  1112  1464 D NetworkPolicy: onUidStateChanged() uid: 10132, isForeground(false, 10)2022-03-29 10:11:13.837 -0400  1112 21193 D WifiConnectivityMonitor.DnsPingerHandler: setCurrentLinkProperties: lp={InterfaceName: wlan0 LinkAddresses: [ fe80::dcea:62ff:fede:fae0/64,10.2.6.19/22 ] DnsAddresses: [ /10.2.8.201,/10.2.8.202 ] Domains: null MTU: 0 ServerAddress: /10.2.8.9 TcpBufferSizes: 524288,1048576,4194304,524288,1048576,4194304 Routes: [ fe80::/64 -> :: wlan0 mtu 0,10.2.4.0/22 -> 0.0.0.0 wlan0 mtu 0,0.0.0.0/0 -> 10.2.4.1 wlan0 mtu 0 ]}2022-03-29 10:11:14.147 -0400  1112 21194 D WifiConnectivityMonitor.DnsThread:  [|208] []2022-03-29 10:11:14.148 -0400  1112  1112 D WifiConnectivityMonitor.NetworkStatsAnalyzer: DNS resultType : 0, responseTime : 2082022-03-29 10:11:14.267 -0400   852 18304 I sensors-hal: handle_sns_client_event:660, [0][15800] accel_sample [-2.024, -9.460,  1.541] 17541378029563
App closed via swipe up and ADB logs after pushing a notification
2022-03-29 10:30:05.453 -0400 1968 2132 D MobileStatusTracker(0/1): onSignalStrengthsChanged signalStrength=SignalStrength:{mCdma=Invalid,mGsm=Invalid,mWcdma=CellSignalStrengthWcdma: ss=-99 ber=2147483647 rscp=-100 ecno=-8 level=1,mTdscdma=Invalid,mLte=Invalid,mNr=Invalid,SignalBarInfo{ wcdmaLevel=3 },rat=3,primary=CellSignalStrengthWcdma} level=3 2022-03-29 10:30:05.454 -0400 1968 2132 D CscParser: OMC path : /product/omc/XAA/conf/customer.xml 2022-03-29 10:30:05.454 -0400 1968 2132 I CscParser: getCustomerPath : omc customer file can read 2022-03-29 10:30:05.454 -0400 1968 2132 E CscParser: update(): xml file exist
2022-03-29 10:30:05.458 -0400 1968 2132 D NetworkController: SignalStrength from intent slotId=0
2022-03-29 10:30:05.589 -0400 852 18288 I sensors-hal: handle_sns_client_event:207, auto_rotation_event_2: mode:255, type:1:0/-2.013,-9.461,1.535
2022-03-29 10:30:05.691 -0400 852 18304 I sensors-hal: handle_sns_client_event:660, [0][45907] accel_sample [-2.007, -9.463, 1.532] 18672803071160
2022-03-29 10:30:06.102 -0400 2909 16754 D ConnectivityManager: StackLog: [android.net.ConnectivityManager.reportNetworkConnectivity(ConnectivityManager.java:3139)] [aggz.i(:com.google.android.gms@[email protected] (190400-434869283):0)] [aggq.run(:com.google.android.gms@[email protected] (190400-434869283):49)] [wex.c(:com.google.android.gms@[email protected] (190400-434869283):6)] [wex.run(:com.google.android.gms@[email protected] (190400-434869283):7)] [java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)] [java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)] [wkb.run(:com.google.android.gms@[email protected] (190400-434869283):0)] [java.lang.Thread.run(Thread.java:920)]
2022-03-29 10:30:06.103 -0400 1112 1793 D ConnectivityService: reportNetworkActive, notify 1 listeners 2022-03-29 10:30:06.103 -0400 1112 4203 D SamsungAlarmManager: Cancel Alarm calling from uid:10099 pid :2909 / OP:PendingIntent{8e6432: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}} 2022-03-29 10:30:06.103 -0400 1112 4203 V SamsungAlarmManager: setLocked to kernel - W:19370719 / NW:18703716, now=18673227 2022-03-29 10:30:06.104 -0400 28677 29320 D NetworkUpdater: onNetworkActive
2022-03-29 10:30:06.104 -0400 28677 29320 D NetworkUpdater: onNetworkActive 2022-03-29 10:30:06.104 -0400 1112 4203 D SamsungAlarmManager: setExact (T:2/F:33/AC:false) 20220329T105756 now=18673228 - CU:10099/CP:2909/OP:PendingIntent{fd41583: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}
2022-03-29 10:30:06.104 -0400 1112 4203 V SamsungAlarmManager: setLocked to kernel - W:19370719 / NW:18703716, now=18673228
2022-03-29 10:30:06.112 -0400 28718 28718 D RNFirebaseMsgReceiver: broadcast received for message
2022-03-29 10:30:06.112 -0400 1112 8775 D SamsungAlarmManager: setExact (T:2/F:33/AC:false) 20220329T103206 now=18673236 - CU:10099/CP:2909/OP:PendingIntent{9afb739: PendingIntentRecord{42eb6e9 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}} 2022-03-29 10:30:06.112 -0400 1112 8775 V SamsungAlarmManager: setLocked to kernel - W:18793233 / NW:18703716, now=18673236 2022-03-29 10:30:06.115 -0400 1112 8775 W ActivityManager: Background start not allowed: service Intent { cmp=io.getamber.app.sandbox/io.invertase.firebase.messaging.ReactNativeFirebaseMessagingHeadlessService (has extras) } to io.getamber.app.sandbox/io.invertase.firebase.messaging.ReactNativeFirebaseMessagingHeadlessService from pid=28718 uid=11955 pkg=io.getamber.app.sandbox startFg?=false 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: Background messages only work if the message priority is set to 'high' 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: android.app.BackgroundServiceStartNotAllowedException: Not allowed to start service Intent { cmp=io.getamber.app.sandbox/io.invertase.firebase.messaging.ReactNativeFirebaseMessagingHeadlessService (has extras) }: app is in background uid UidRecord{acbf1b u0a1955 RCVR bg:+6m31s211ms idle change:uncached procs:0 seq(0,0,0)} 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1940) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ContextImpl.startService(ContextImpl.java:1886) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.content.ContextWrapper.startService(ContextWrapper.java:791) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.content.ContextWrapper.startService(ContextWrapper.java:791) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at io.invertase.firebase.messaging.ReactNativeFirebaseMessagingReceiver.onReceive(ReactNativeFirebaseMessagingReceiver.java:53) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ActivityThread.handleReceiver(ActivityThread.java:4763) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ActivityThread.access$1800(ActivityThread.java:310) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2294) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.os.Handler.dispatchMessage(Handler.java:106) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.os.Looper.loopOnce(Looper.java:226) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.os.Looper.loop(Looper.java:313) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at android.app.ActivityThread.main(ActivityThread.java:8641) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at java.lang.reflect.Method.invoke(Native Method) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:567) 2022-03-29 10:30:06.116 -0400 28718 28718 E RNFirebaseMsgReceiver: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1133)
2022-03-29 10:30:06.126 -0400 1112 4203 D SamsungAlarmManager: Cancel Alarm calling from uid:10099 pid :2909 / OP:PendingIntent{1a38f2c: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}
2022-03-29 10:30:06.126 -0400 1112 4203 V SamsungAlarmManager: setLocked to kernel - W:18793233 / NW:18703716, now=18673249 2022-03-29 10:30:06.126 -0400 1112 4203 D SamsungAlarmManager: setExact (T:2/F:33/AC:false) 20220329T105756 now=18673250 - CU:10099/CP:2909/OP:PendingIntent{4b8df5: PendingIntentRecord{1d5ae06 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}} 2022-03-29 10:30:06.126 -0400 1112 4203 V SamsungAlarmManager: setLocked to kernel - W:18793233 / NW:18703716, now=18673250
2022-03-29 10:30:06.145 -0400 28718 30503 W FirebaseMessaging: Missing Default Notification Channel metadata in AndroidManifest. Default value will be used.
2022-03-29 10:30:06.149 -0400 1112 4203 D ApplicationPolicy: isStatusBarNotificationAllowedAsUser: packageName = io.getamber.app.sandbox,userId = 0
2022-03-29 10:30:06.150 -0400 1112 4203 D ApplicationPolicy: isStatusBarNotificationAllowedAsUser: packageName = io.getamber.app.sandbox,userId = 0
2022-03-29 10:30:06.154 -0400 1112 8775 D SamsungAlarmManager: Cancel Alarm calling from uid:10099 pid :2909 / OP:PendingIntent{66672d7: PendingIntentRecord{42eb6e9 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}} 2022-03-29 10:30:06.154 -0400 1112 8775 V SamsungAlarmManager: setLocked to kernel - W:19370719 / NW:18703716, now=18673277
2022-03-29 10:30:06.180 -0400 3757 3757 D BoundBrokerSvc: onBind: Intent { act=com.google.android.gms.measurement.START pkg=com.google.android.gms } 2022-03-29 10:30:06.180 -0400 3757 3757 D BoundBrokerSvc: Loading bound service for intent: Intent { act=com.google.android.gms.measurement.START pkg=com.google.android.gms }
2022-03-29 10:30:06.236 -0400 1112 8775 D SamsungAlarmManager: Cancel Alarm calling from uid:10099 pid :3757 / OP:PendingIntent{96c562e: PendingIntentRecord{eeac38c com.google.android.gms/com.google.android.gms.measurement broadcastIntent}}
2022-03-29 10:30:06.284 -0400 1968 1968 D NetworkController.WifiSignalController: notifyListener: enabled=true, connected=true, inetCondition=1, isDefault=true, shouldForceHide=false
2022-03-29 10:30:06.307 -0400 964 964 I SurfaceFlinger: SFWD update time=18673431643291
2022-03-29 10:30:06.318 -0400 18504 18520 W ImageReader_JNI: Unable to acquire a buffer item, very likely client tried to acquire more than maxImages buffers
2022-03-29 10:30:06.353 -0400 1112 1112 W NotificationPrefHelper: Got a isNotificationAlertsEnabled : true
2022-03-29 10:30:06.353 -0400 1112 1112 I AccessibilityManager: semStartFlashNotification notitype = null, getOpPackageName = android, sbnPackageName = io.getamber.app.sandbox 2022-03-29 10:30:06.353 -0400 1112 1112 D AccessibilityManagerService: semStartFlashNotification 2022-03-29 10:30:06.353 -0400 1112 1112 I AccessibilityManagerService: semStartFlashNotificationInner() type=Default, pkgName=android, token=android.os.Binder@4d2a334, sbnPkgName=io.getamber.app.sandbox, previewType=0 2022-03-29 10:30:06.353 -0400 1112 1112 D AccessibilityManagerService: Can not use light notification 2022-03-29 10:30:06.353 -0400 1112 1112 W NotificationPrefHelper: Got a isNotificationAlertsEnabled : true 2022-03-29 10:30:06.357 -0400 1112 1112 W NotificationHistory: Attempted to add notif for locked/gone/disabled user 0
2022-03-29 10:30:06.360 -0400 15981 15981 I Launcher.NotificationListener: onNotificationPosted : io.getamber.app.sandbox number : 0
2022-03-29 10:30:06.360 -0400 15981 16014 I Launcher.NotificationListener: notificationIsValidForUI : io.getamber.app.sandbox missingTitleAndText : false isGroupHeader : false
2022-03-29 10:30:06.360 -0400 15981 15981 I FolderIconView: applyDotState FolderInfo : Google display : 1 count : 0 2022-03-29 10:30:06.361 -0400 15981 15981 I FolderIconView: applyDotState FolderInfo : Samsung display : 1 count : 0 2022-03-29 10:30:06.361 -0400 15981 15981 I IconView: applyDotState itemInfo : Amber.sandbox display : 1 count : 2
2022-03-29 10:30:06.361 -0400 7364 7364 I Edge.badge: updateBadge item=key=0|io.getamber.app.sandbox|0|FCM-Notification:18673272|11955, count=1
2022-03-29 10:30:06.375 -0400 1968 1968 D InterruptionStateProvider: No bubble up: not allowed to bubble: 0|io.getamber.app.sandbox|0|FCM-Notification:18673272|11955 2022-03-29 10:30:06.375 -0400 1968 1968 D InterruptionStateProvider: No heads up: unimportant notification: 0|io.getamber.app.sandbox|0|FCM-Notification:18673272|11955
2022-03-29 10:30:06.378 -0400 1968 2132 D PeopleSpaceWidgetMgr: Sbn doesn't contain valid PeopleTileKey: null/0/io.getamber.app.sandbox
2022-03-29 10:30:06.459 -0400 1968 1968 D QS : setQSExpansion 0.0 -117.6
2022-03-29 10:30:06.459 -0400 1968 1968 D QS : setQSExpansion 0.0 -117.6
2022-03-29 10:30:06.464 -0400 1968 18310 D IndicatorGardenInputProperty: updateRotation() prv:-1 >> new:0

jinshin1013 avatar Mar 29 '22 14:03 jinshin1013

Android, or perhaps this flavor of Android, has apparently gotten more strict about energy budget and force close:

Hi there - I think this is the case where you have told the operating system "stop running this app", and basically it believed you.

https://dontkillmyapp.com Perhaps something like: https://notifee.app/react-native/docs/android/background-restrictions ?

mikehardy avatar Mar 29 '22 14:03 mikehardy

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 the community's attention?

This issue will be closed in 15 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Apr 28 '22 01:04 stale[bot]

Hello, there is no news on this topic, but I have the same problem. I previously use https://github.com/zo0r/react-native-push-notification and i didn't have any issues but this lib is no longer maintain.

Do you have any solution ?

ederwan avatar Oct 27 '22 14:10 ederwan

notifee.app

mikehardy avatar Oct 27 '22 23:10 mikehardy

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 Dec 05 '22 19:12 github-actions[bot]