-
-
Notifications
You must be signed in to change notification settings - Fork 172
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
Push Receiver stops getting notifications #934
Comments
@djm181 i'm not able to reproduce this issue. I've had homebridge running for 6 days and it's still getting push notifications 😕. Have you seen this same behavior since first reporting? |
I've also not been able to reproduce this. I've been testing the push notifications in the ring-mqtt codebase since @dgreif first introduced them during v10-beta and, so far, I've not seen push notifications fail and I've definitely had them running, for 10+ days in some cases, on both my production and development instances. I've also definitely not had to generate any new tokens. Just in case, are you definitely monitoring |
I haven't seen this behavior since reporting this but I made changes to my app to try and get around it. Specifically I changed the I do monitor onRefreshTokenUpdated and save the new tokens. The Because my use case can result in new cameras being shared from time to time, I do have a periodic job to refresh the list of cameras, which is admittedly a bit of a hack: // conn is my RingApi instance
conn.disconnect();
conn["locationsPromise"] = conn.fetchAndBuildLocations(); I don't think I see any way for this to be causing the issue I'm seeing though, especially since I experience it across restarts of the app. I'll make the systemId stable again and see if the problem reoccurs. |
Hmm, one other thing I think is a little out of the ordinary for me - I have previously use the same systemId for logging into two different ring accounts simultaneously. Different credentials and refresh tokens obviously, but I wonder if the ring system has any issue with this from a sessions standpoint. |
Interesting, it's something worth investigating. I can at least see how the Ring backend system might not expect this to be possible and it might cause unexplained behavior. I continue to have no issues with my instances and, so far, no users that have upgraded to ring-mqtt v5 have reported this issue, but that of course does not mean it doesn't exist as it's only been about a week since it was released. My current prod/test instances have currently been up for 5 days, so I'll keep monitoring. |
@djm181 that definitely seems like a scenario that would cause problems. I believe the hardware_id (generated from systemId) is intended to be unique, and is the id used to update the push notification token. Sharing that id between two accounts could definitely cause some odd problems in Rings system. Since we haven't had any other reports, I think it's safe to assume that's the root issue here. Thanks for reporting it though, keep the info coming 😄 |
Bug Report
Describe the Bug
A long-running connection to the Ring API stops receiving notifications through the push receiver. Once the account is in this state, recycling the connection (or even the process) has no effect - the push receiver still receives no dings.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Dings should come through forever.
Screenshots/Logs
Additional context
The only workaround I've found once in this state is to remove the Authorized Devices from the account and generate a fresh refresh token. Somehow it appears the token is getting "tainted" with Ring and not receiving push notifications any more. I'm guessing this is something to do with the credentials for FCM not being updated correctly, but it's not clear to me what the issue here would be.
Environment
The text was updated successfully, but these errors were encountered: