You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am allowing users to add a post optimistically, such that if it fails due to network error, the mutation will by resent using react-query retry flag when the device reconnects. The problem is that, after enabling retry for mutation, the status of the mutate call does not change to error even after the network error has occurred and instead the status shows loading.
Also, as I am adding the post optimistically I want to cancel queries for re-fetching posts until the new post has been added and currently there's no way to cancel certain queries on mutation retry.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I am allowing users to add a post optimistically, such that if it fails due to network error, the mutation will by resent using react-query
retry
flag when the device reconnects. The problem is that, after enabling retry for mutation, the status of the mutate call does not change toerror
even after the network error has occurred and instead the status showsloading
.Also, as I am adding the post optimistically I want to cancel queries for re-fetching posts until the new post has been added and currently there's no way to cancel certain queries on mutation retry.
Beta Was this translation helpful? Give feedback.
All reactions