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

Fix dedup ignoring torn down query operations #281

Merged
merged 1 commit into from
Jun 8, 2019

Conversation

kitten
Copy link
Member

@kitten kitten commented Jun 8, 2019

Fix #280

When a query was torn down, the dedup exchange wasn't
removing its key from the inFlight keys.

This was causing us to ignore torn down queries forever.

When a query was torn down, the dedup exchange wasn't
removing its key from the inFlight keys.

This was causing us to ignore torn down queries forever.
@kitten kitten added bug 🐛 Oh no! A bug or unintented behaviour. high priority 💥 labels Jun 8, 2019
Copy link
Contributor

@andyrichardson andyrichardson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍👍👍

inFlight.add(key);
}
const afterOperationResult = ({ operation }: OperationResult) => {
inFlightKeys.delete(operation.key);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason for not having this inline?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to clean it up; I thought having names like afterOperationResult could help when someone's trying to figure out how those work

@kitten kitten merged commit ef52618 into master Jun 8, 2019
@kitten kitten deleted the fix/dedup-ignoring-teardown branch June 8, 2019 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Oh no! A bug or unintented behaviour.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Previously canceled queries are not refetched, but fetching is true
2 participants