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

Active Queries never go away #815

Open
kaysond opened this issue Feb 22, 2022 · 0 comments
Open

Active Queries never go away #815

kaysond opened this issue Feb 22, 2022 · 0 comments
Labels

Comments

@kaysond
Copy link

kaysond commented Feb 22, 2022

Intended outcome:
Active Queries should not multiply when the component is re-rendered

Actual outcome:
Every time a component that uses useQuery() is unmounted and re-rendered, the query is appended to the list of "Active Queries"
image

How to reproduce the issue:
I posted some more context/questions on the forums here: https://community.apollographql.com/t/im-new-to-apollo-ive-built-a-functional-app-server-client-and-now-i-have-a-few-questions-about-queries-caching-and-dev-tools/2793/2
It's entirely possible that this is user error, but as I've not received any responses on the forums, I'm creating an issue here as well in case it is in fact an extension issue.

If it's not an obvious bug or obvious user error, I can try to create a minimal repro.

The gist of it is that I have conditionally rendered components (like modals) using useQuery(). If I render that component, it adds a query to "Active Queries". If I destroy the component, the Active Query stays there. The same thing happens if I change the props to the component (which changes the variable passed to the query).

I don't have a massive memory leak, so I don't expect that the queries are all actually sitting there, active, but it makes the extension very difficult to use.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Firefox (happens with Chrome too)
  • Browser version: 91.6.0esr
  • Extension version: 4.0.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants