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

FCM: Disconnect FCM Service #847

Closed
LongLostPenPal opened this issue Oct 29, 2020 · 8 comments
Closed

FCM: Disconnect FCM Service #847

LongLostPenPal opened this issue Oct 29, 2020 · 8 comments
Labels
api: auth closed-by-bot needs-info Need information for the developer stale Don't have recent activity

Comments

@LongLostPenPal
Copy link

LongLostPenPal commented Oct 29, 2020

[REQUIRED] Please fill in the following fields:

  • Unity editor version: 2019.2.21f
  • Firebase Unity SDK version: 6.10.0
  • Xcode: 11.5
  • Problematic Firebase Component: _____ (Auth, Database, etc.)
  • Other Firebase Components in use:FirebaseAnalytics/FirebaseCrashlytics/FirebaseMessaging/FirebaseRemoteConfig
  • Additional SDKs you are using: Facebook
  • Platform you are using the Unity editor on: Mac
  • Platform you are targeting: iOS
  • Scripting Runtime: IL2CPP

[REQUIRED] Please describe the issue here:

(Please list the full steps to reproduce the issue. Include device logs, Unity logs, and stack traces if available.)

Steps to reproduce:

Have you been able to reproduce this issue with just the Firebase Unity quickstarts (this GitHub project)?
What's the issue repro rate? (eg 100%, 1/5 etc)

What happened? How can we make the problem occur?
This could be a description, log/console output, etc.

If you have a downloadable sample project that reproduces the bug you're reporting, you will
likely receive a faster response on your issue.

Relevant Code:

-> applicationDidEnterBackground()
2020-10-29 17:19:46.427961+0800 xxxxxxxFCM: Disconnect FCM service
2020-10-29 17:19:46.428506+0800 xxxxxxx FCM: Disconnect FCM service
-> applicationWillEnterForeground()
2020-10-29 17:19:47.476913+0800 xxxxxxx FCM: Connected to FCM
-> applicationDidBecomeActive()

I do all the step the doc tells. Doc .
It works well on android,but not work on ios. I received the token, and push a test notifacition at firebase console,but can't receive message in background. When I back to the app, I Also cant receive the message.

@LongLostPenPal
Copy link
Author

LongLostPenPal commented Oct 30, 2020

i dont konw why , but it worked when i re-install several times.... and when app enterbackground fcm still print Disconnect FCM service . maybe not config FCM APNs

@LongLostPenPal
Copy link
Author

LongLostPenPal commented Oct 30, 2020

why i get this warning , and no callback in unity [Firebase.Messaging.FirebaseMessaging.MessageReceived]
`

-> applicationWillEnterForeground()
2020-10-30 15:29:56.701636+0800 xxxxx Warning: UNUserNotificationCenter delegate received call to -userNotificationCenter:didReceiveNotificationResponse:withCompletionHandler: but the completion handler was never called.
2020-10-30 15:29:56.720139+0800 xxxxx [] nw_read_request_report [C34] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:56.720214+0800 xxxxx [] nw_read_request_report [C37] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:56.720258+0800 xxxxx [] nw_read_request_report [C33] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:56.720297+0800 xxxxx [] nw_read_request_report [C34] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:56.720989+0800 xxxxx [] nw_read_request_report [C37] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:56.722031+0800 xxxxx [] nw_read_request_report [C33] Receive failed with error "Software caused connection abort"
2020-10-30 15:29:57.020859+0800 xxxxx FCM: Connected to FCM
-> applicationDidBecomeActive()

`

@patm1987
Copy link

patm1987 commented Nov 3, 2020

Hi @LongLostPenPal ,

This seems like an issue better suited to Firebase Support. They'll have much better debugging tools to debug your backend configuration.

To keep helping you here, I will need to find some way to sync a local configuration to what you have. Would you be able to reproduce your issue in the Messaging quickstart? By adding your own GoogleService-Info.plist and changing the bundle id to match your current app, you should be able to get it talking to your own Firebase instance.

Would you also be able to upgrade to the latest Unity SDK to see if that helps (6.16.1).
Share more of your logs (with the argument -FIRDebugEnabled set in XCode).
Verify that you have not disabled method swizzling (you would have to do this manually in your Info.plist).
Verify that you've enabled push notifications and background modes. This may reset on a clean build.
Confirm that you are not using Unity's notification system.

Let me know if you opt to go the Firebase Support route or if you have the information above.

Thanks! And apologies for not having a quick and easy answer for you!
--Patrick

@patm1987 patm1987 added needs-info Need information for the developer and removed new New issue. labels Nov 3, 2020
@LongLostPenPal
Copy link
Author

Hi @LongLostPenPal ,

This seems like an issue better suited to Firebase Support. They'll have much better debugging tools to debug your backend configuration.

To keep helping you here, I will need to find some way to sync a local configuration to what you have. Would you be able to reproduce your issue in the Messaging quickstart? By adding your own GoogleService-Info.plist and changing the bundle id to match your current app, you should be able to get it talking to your own Firebase instance.

Would you also be able to upgrade to the latest Unity SDK to see if that helps (6.16.1).
Share more of your logs (with the argument -FIRDebugEnabled set in XCode).
Verify that you have not disabled method swizzling (you would have to do this manually in your Info.plist).
Verify that you've enabled push notifications and background modes. This may reset on a clean build.
Confirm that you are not using Unity's notification system.

Let me know if you opt to go the Firebase Support route or if you have the information above.

Thanks! And apologies for not having a quick and easy answer for you!
--Patrick

Thanks for replying!

Would you be able to reproduce your issue in the Messaging quickstart?

I will try immediately when I have time

Would you also be able to upgrade to the latest Unity SDK to see if that helps (6.16.1).

I upgrade to 6.16.1 and it got the same situation

Share more of your logs (with the argument -FIRDebugEnabled set in XCode).

FullLogs

Verify that you have not disabled method swizzling (you would have to do this manually in your Info.plist).

I test disabled/enabled method swizzling , Both get the same situation

Verify that you've enabled push notifications and background modes. This may reset on a clean build.

there is no problem

Confirm that you are not using Unity's notification system.

I'm using Unity's notification system.

Thanks!

@google-oss-bot google-oss-bot added needs-attention Need Googler's attention and removed needs-info Need information for the developer labels Nov 4, 2020
@ghost
Copy link

ghost commented Nov 5, 2020

Hi @LongLostPenPal ,

This seems like an issue better suited to Firebase Support. They'll have much better debugging tools to debug your backend configuration.

To keep helping you here, I will need to find some way to sync a local configuration to what you have. Would you be able to reproduce your issue in the Messaging quickstart? By adding your own GoogleService-Info.plist and changing the bundle id to match your current app, you should be able to get it talking to your own Firebase instance.

Would you also be able to upgrade to the latest Unity SDK to see if that helps (6.16.1).
Share more of your logs (with the argument -FIRDebugEnabled set in XCode).
Verify that you have not disabled method swizzling (you would have to do this manually in your Info.plist).
Verify that you've enabled push notifications and background modes. This may reset on a clean build.
Confirm that you are not using Unity's notification system.

Let me know if you opt to go the Firebase Support route or if you have the information above.

Thanks! And apologies for not having a quick and easy answer for you!
--Patrick

Hi, I have a question

If i'm using both Unity's notification system and firebase FCM is possible that they are interfering between them?

@patm1987
Copy link

patm1987 commented Nov 6, 2020

There has been at least one other bug associated with the presence of the Mobile Notifications package. If you're able, it would be really useful to know if we can isolate your issue to this.

If you can try reproducing your issue in the Quickstart, and let us know if it doesn't occur with the vanilla quickstart but does after adding Mobile Notifications - that would go a good way towards getting to the bottom of the issue!

@patm1987 patm1987 added needs-info Need information for the developer and removed needs-attention Need Googler's attention labels Nov 6, 2020
@google-oss-bot
Copy link

Hey @LongLostPenPal. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

@google-oss-bot google-oss-bot added the stale Don't have recent activity label Nov 13, 2020
@google-oss-bot
Copy link

Since there haven't been any recent updates here, I am going to close this issue.

@LongLostPenPal if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.

@firebase firebase locked and limited conversation to collaborators Dec 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api: auth closed-by-bot needs-info Need information for the developer stale Don't have recent activity
Projects
None yet
Development

No branches or pull requests

3 participants