-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Calling clearStore
while a lazyQuery is pending causes an error
#11988
Comments
In the codesandbox we see a race condition here: apollo-client/src/react/hooks/useLazyQuery.ts Lines 226 to 255 in c210a03
The question is how to best act on this:
We need to discuss this internally. Putting it on the agenda for our next meeting. |
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Hey @jerelmiller, I get the same error stack trace error in
node_modules/@apollo/client/react/hooks/useQuery.js
To reproduce the issue, go to search in the sandbox preview and press "OK" to reproduce the bug. I ran a lazy query and then quickly performed
clearStore()
in/src/components/Search.js
to simulate it.CodeSandbox
Thanks for looking into it!
Originally posted by @DerekWang98 in #11846 (comment)
The text was updated successfully, but these errors were encountered: