Skip to content

Queries can show incorrect data #5924

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

Closed
shepherdjerred opened this issue Aug 29, 2023 · 3 comments
Closed

Queries can show incorrect data #5924

shepherdjerred opened this issue Aug 29, 2023 · 3 comments
Labels
duplicate This issue or pull request already exists package: vue-query

Comments

@shepherdjerred
Copy link

Describe the bug

In some cases, TanStack query can return incorrect data when multiple related keys are used

Your minimal, reproducible example

https://stackblitz.com/edit/vitejs-vite-a9azfw?file=src%2FApp.vue

Steps to reproduce

  1. Go to this StackBlitz example.
  2. Read through the synopsis and expected behavior
  3. Click "swap" twice
  4. Notice that the invariants have been violated, and that incorrect data is being shown

Expected behavior

Reactivity updates should happen all at once so that invalid states cannot be observed

How often does this bug happen?

Every time

Screenshots or Videos

No response

Platform

macOS Chrome 116.0.5845.110

Tanstack Query adapter

vue-query

TanStack Query version

4.34.0

TypeScript version

5.0.2

Additional context

No response

@TkDodo
Copy link
Collaborator

TkDodo commented Aug 29, 2023

@DamianOsipiuk fyi

@Mini-ghost
Copy link
Contributor

This issue should be the same as #5910

@TkDodo
Copy link
Collaborator

TkDodo commented Aug 29, 2023

thanks, closing as duplicate then.

@TkDodo TkDodo closed this as not planned Won't fix, can't repro, duplicate, stale Aug 29, 2023
@TkDodo TkDodo added the duplicate This issue or pull request already exists label Aug 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists package: vue-query
Projects
None yet
Development

No branches or pull requests

3 participants