Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Clicking a push notification does not trigger the click event handler on fresh installs #1737

Open
2 of 3 tasks
mykel-unwritten opened this issue Sep 1, 2024 · 0 comments

Comments

@mykel-unwritten
Copy link

What happened?

In react native, when app is installed fresh and then you send a push notification from one signal dashboard (either in foreground or background), console log is not triggered in inside the click event. However, when the app is relaunched, it works fine

Steps to reproduce?

1. install app
2. launch app
3. send push notification from one signal dashboard
4. while in foreground/background, push notification is received
5. click on the notification banner
6. event handler is not triggered

What did you expect to happen?

event handler should be triggered regardless if the app is fresh installed or relaunched

React Native OneSignal SDK version

5.2.3

Which platform(s) are affected?

  • iOS
  • Android

Relevant log output

nw_connection_add_timestamp_locked_on_nw_queue [C13] Hit maximum timestamp count, will start dropping events
VERBOSE: onesignalUserNotificationCenter:willPresentNotification:withCompletionHandler:
VERBOSE: onesignalUserNotificationCenter:willPresentNotification:withCompletionHandler: Fired! test
VERBOSE: finishProcessingNotification: Fired!
VERBOSE: Notification display type: 7
VERBOSE: notificationReceived called! opened: NO
VERBOSE: onesignalUserNotificationCenter:willPresentNotification:withCompletionHandler:
VERBOSE: onesignalUserNotificationCenter:willPresentNotification:withCompletionHandler: Fired! test
VERBOSE: finishProcessingNotification: Fired!
VERBOSE: Notification display type: 7
VERBOSE: notificationReceived called! opened: NO
VERBOSE: callLegacyAppDeletegateSelector:withCompletionHandler: Fired!
VERBOSE: oneSignalReceiveRemoteNotification:UserInfo:fetchCompletionHandler:
VERBOSE: notificationReceived called! opened: NO
VERBOSE: finishProcessingNotification: call completionHandler with options: 7
VERBOSE: finishProcessingNotification: call completionHandler with options: 7
VERBOSE: onesignalUserNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:
VERBOSE: onesignalUserNotificationCenter:didReceiveNotificationResponse:withCompletionHandler: Fired!
VERBOSE: notificationReceived called! opened: YES
VERBOSE: HTTP Request (OSRequestSubmitNotificationOpened) with URL: https://api.onesignal.com/notifications/677a473a-9b36-4ef6-9c86-48bb83fd7320, with parameters: {
  "opened" : true,
  "player_id" : "e42acd30-4e0d-48be-a5a2-58e610a046a5",
  "app_id" : "4b9c093f-9003-4432-9032-f11217aad546",
  "device_type" : 0
}
VERBOSE: handleNotificationOpened called! isActive: YES notificationId: 677a473a-9b36-4ef6-9c86-48bb83fd7320
VERBOSE: onesignalUserNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:
VERBOSE: onesignalUserNotificationCenter:didReceiveNotificationResponse:withCompletionHandler: Fired!
VERBOSE: notificationReceived called! opened: YES
VERBOSE: Duplicate notif received. Not calling opened handler.
VERBOSE: callLegacyAppDeletegateSelector:withCompletionHandler: Fired!
VERBOSE: oneSignalReceiveRemoteNotification:UserInfo:fetchCompletionHandler:
VERBOSE: notificationReceived called! opened: NO
VERBOSE: network response (OSRequestSubmitNotificationOpened) with URL https://api.onesignal.com/notifications/677a473a-9b36-4ef6-9c86-48bb83fd7320: {
    httpStatusCode = 200;
    success = 1;
}
nw_read_request_report [C35] Receive failed with error "Socket is not connected"
nw_read_request_report [C35] Receive failed with error "Socket is not connected"
nw_read_request_report [C35] Receive failed with error "Socket is not connected"
nw_read_request_report [C37] Receive failed with error "Operation timed out"
nw_read_request_report [C37] Receive failed with error "Operation timed out"
nw_read_request_report [C37] Receive failed with error "Operation timed out"
nw_endpoint_flow_fillout_data_transfer_snapshot copy_info() returned NULL
(ADVICE) View #5955 of type RCTView has a shadow set but cannot calculate shadow efficiently. Consider setting a background color to fix this, or apply the shadow to a more specific component.
(ADVICE) View #5955 of type RCTView has a shadow set but cannot calculate shadow efficiently. Consider setting a background color to fix this, or apply the shadow to a more specific component.
nw_read_request_report [C39] Receive failed with error "Socket is not connected"
nw_read_request_report [C39] Receive failed with error "Socket is not connected"
nw_read_request_report [C39] Receive failed with error "Socket is not connected"

Code of Conduct

  • I agree to follow this project's Code of Conduct
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant