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

resetStore() doesn't work after React upgrade to 17.0.2 #9106

Closed
ageorgi87 opened this issue Nov 23, 2021 · 2 comments
Closed

resetStore() doesn't work after React upgrade to 17.0.2 #9106

ageorgi87 opened this issue Nov 23, 2021 · 2 comments

Comments

@ageorgi87
Copy link

Intended outcome:

I would like to upgrade react from version 16.14.0 to version 17.0.2
Since I did, the function resetStore (https://www.apollographql.com/docs/react/api/core/ApolloClient/#ApolloClient.resetStore) doesn't seems to work anymore.
More specifically, it seems to be the reFetchObservableQueries function, called by resetStore(), which seems to block.

Actual outcome:

When I sign out from a session on my application, the resetStore function is called.
It used to work perfectly fine but since the react update, the code reading stops at the resetStore function.

My code :
Capture d’écran 2021-11-23 à 14 33 43

My console :
Capture d’écran 2021-11-23 à 14 37 32
Capture d’écran 2021-11-23 à 14 38 29

Versions

System:
OS: macOS 11.6
Binaries:
Node: 14.17.6 - ~/.nvm/versions/node/v14.17.6/bin/node
Yarn: 1.19.1 - ~/.nvm/versions/node/v14.17.6/bin/yarn
npm: 6.14.15 - ~/.nvm/versions/node/v14.17.6/bin/npm
Browsers:
Chrome: 95.0.4638.69
Safari: 15.1
npmPackages:
@apollo/react-hooks: ^3.0.1 => 3.1.5
apollo-cache-inmemory: ^1.2.9 => 1.6.6
apollo-client: ^2.4.1 => 2.6.10
apollo-link-http: ^1.5.4 => 1.5.17
react-apollo: ^3.0.1 => 3.1.5

Thanks for your help !

@benjamn
Copy link
Member

benjamn commented Dec 6, 2021

@ageorgi87 It looks like you're still using Apollo Client v2 (apollo-client and apollo-cache-inmemory have been replaced by the unified @apollo/client package in AC3, as described in the migration guide).

To be honest with you, while we are actively chasing the React team's latest developments with AC3 (#8365, #8458, apollographql/apollo-feature-requests#366, etc.), we have no plans to update the old AC2 packages to work with the latest versions of React. If you have time to dig into the problem and you can come up with a specific change you'd like to see backported to AC2, we might consider it, but I can't promise you I/we can spend much time on this.

@bignimbus
Copy link
Contributor

Hi all, I'll close this thread for lack of actionable items for the team. Thanks a bunch!

@bignimbus bignimbus closed this as not planned Won't fix, can't repro, duplicate, stale Dec 5, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 14, 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

No branches or pull requests

3 participants