-
Notifications
You must be signed in to change notification settings - Fork 894
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
Error: Uncaught (in promise): cancelled at Refresher.stop() #7805
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
Hi @bpetrov98, Do you have any details on the error at all (stack trace, etc) so that we can narrow down where the issue might be? Thanks! |
Hi @DellaBitta, I can provide you with the error stack trace in production, where I've replaced our domain with example.com.
|
Hi @bpetrov98, Do you happen to have an unobfuscated stack trace that points to the error within Firebase? I think we found a potential scenario that might cause this error but it would be helpful to know for sure. Additionally, given our investigation it's our assumption that this error doesn't actually cause any negative behavior (other than spamming you with emails) but it would be helpful if you could confirm that. Do you know if your app continues to operate as expected after the error? Thanks! |
Hi again @DellaBitta, We actually don't have any other stack trace, other than the one provided above. Thankfully, this error doesn't actually cause any negative behaviour. We just want to understand why and how it happens and try to prevent it in the future. We've used many catch blocks to try and catch the error, but unfortunately we couldn't catch it. |
Ok, I'll see if we can attempt to sort this out internally to the SDK. |
Install catch handlers for promises in the Derferred object used by in AppCheck. There were some cases where the promise was cancelled and this bubbled up error messages to our clients' applications despite this being expected behavior. This change is to alleviate the logging reported in issue #7805.
Hi @bpetrov98, We've identified that the cancelled promise is part of standard App Check SDK behavior, but I just merged a PR that should suppress the propagation of an error message to the console logs. The change will be in our next release. I'll update this issue when it's available. Thanks for the report! |
Thank you for your assistance and quick response, @DellaBitta :) |
Hi @bpetrov98, Firebase JS SDK v10.7.1 has been released. Can you test it out and let us know if there's still an issue? Thanks! |
Hi, @DellaBitta, We just updated to the latest version yesterday and unfortunately this morning we got the same error in our email inbox. |
Hi @bpetrov98, That's unfortunate. The good news is that this is expected behavior, and it shouldn't cause any adverse effects on the app itself. Have you found that not to be the case at all? Is the stack trace exactly the same or is the promise not being caught in another location. Also do you have any information about what the app is doing when this stack trace appears? Is the behavior easily reproducible by you, or is it only an issue for a particular customer? Thanks! |
We can't really reproduce the issue. The stack trace is exactly the same and sometimes randomly while sitting on a page it starts happening. It's just random, but I'm somehow sure that it comes from the Proactive Refresh of App Check. I know that it's expected behaviour, but I find it wrong to get errors like this. |
Hi @bpetrov98, I just wanted to confirm that the user encountering the problem has been using the latest and greatest version of the Firebase SDK ( I ask because our previous attempt at fixing this problem should have prevented this issue from being encountered again, but that's based on our limited knowledge about what is actually going wrong. We recently reviewed this issue again with the whole engineering team. I'm sorry to say that we've unsure what else could be triggering this exception given the information that has been provided. If you can provide any more information about how to reproduce this issue then we'd definitely look into this further, but unfortunately, as of now we're not certain what's causing it, and why the attempted fix didn't work. |
Hey @bpetrov98. 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! |
Since there haven't been any recent updates here, I am going to close this issue. @bpetrov98 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. |
Hi, @DellaBitta, |
Hi @bpetrov98, that's great news! Thank you very much for circling back with us! |
Operating System
Windows 11
Browser Version
Chrome Version 119.0.6045.160 (Official Build) (64-bit)
Firebase SDK Version
9.17.2
Firebase SDK Product:
AppCheck
Describe your project's tooling
Angular 15.0.0
Describe the problem
Sometimes we get an uncaught promise error, which we can't find a way to catch and we get an email every time it happens on an user device. I also encountered this error in production, but it seems that the application works fine the whole time. If I don't refresh the page, the uncaught promise error won't stop showing and it spams our emails, because we send an email every time there is an error in our application.
Steps and code to reproduce issue
We actually don't know how to reproduce this issue, because it happens randomly, so any suggestions or fixes will be appreciated.
Here is the code for our Firebase Service:
The text was updated successfully, but these errors were encountered: