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 #647 - Read store in returnPartialData mode if the previous queries failed or were cancelled #696

Merged
merged 7 commits into from
Sep 29, 2016

Conversation

rricard
Copy link
Contributor

@rricard rricard commented Sep 22, 2016

Fixes #647

  • Define stopped queries as stopped instead of deleting them
  • When resolving a stopped or failed query in an update scenario, enable returnPartialData for resolution
  • Test the case when a more previous query failed

TODO:

  • If this PR is a new feature, reference an issue where a consensus about the design was reached (not necessary for small changes)
  • Make sure all of the significant new logic is covered by tests
  • Rebase your changes on master so that they can be merged easily
  • Make sure all tests and linter rules pass
  • Update CHANGELOG.md with your change
  • Add your name and email to the AUTHORS file (optional)
  • If this was a change that affects the external API, update the docs and post a link to the PR in the discussion

@rricard
Copy link
Contributor Author

rricard commented Sep 22, 2016

@helfer I think this PR will be much better than the previous, let me know if there is anything bothering you. I also added a more complex test that actually represents a more complex flow.

@rricard rricard added ready and removed in progress labels Sep 22, 2016
@rricard
Copy link
Contributor Author

rricard commented Sep 27, 2016

@helfer are you back ? can you review this ?

@rricard
Copy link
Contributor Author

rricard commented Sep 27, 2016

I'll just rebase ;)

rricard added a commit that referenced this pull request Sep 27, 2016
@helfer
Copy link
Contributor

helfer commented Sep 28, 2016

@rricard This looks great, I'll take a closer look tomorrow!

@helfer
Copy link
Contributor

helfer commented Sep 29, 2016

@rricard Thanks a lot! I think the code looks good, but I'm a bit hesitant to merge it because I'm not sure what the effects will be downstream, both in the updateQueries functions and in the components that expect loading to stay true when the query was stopped.

@rricard
Copy link
Contributor Author

rricard commented Sep 29, 2016

That's a valid concern. However, whatever we're doing here it'll be better than crashing the app because a previous query failed or was canceled. It was literally a bug breaking our app super easily. I mean, I prefer dealing with potential bad effects created by this PR (for now we didn't got any bad effects from this in our fairly complex app) than having something that will crash often for no real reasons.

@rricard
Copy link
Contributor Author

rricard commented Sep 29, 2016

In the same kind #724 improves a lot our general stability as well. I know that both PRs goes pretty deep but they tend to avoid a lot of hassle afterwards.

@helfer
Copy link
Contributor

helfer commented Sep 29, 2016

@rricard Ok, I see. I'll see if I can merge them and release a version before we start refactoring then.

@rricard
Copy link
Contributor Author

rricard commented Sep 29, 2016

@helfer thanks ! For the refactor, don't hesitate to ping me. I would be glad to help!

@helfer
Copy link
Contributor

helfer commented Sep 29, 2016

Ok, I'll merge this now, but we'll probably refactor the logic quite a bit over the next few days. I'll release a version before we start so you can get rid of those pesky errors.

@jbaxleyiii jbaxleyiii deleted the fix-647-refactored branch July 20, 2017 17:39
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants