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 recently cleaned up some code in our project and removed all fields from a Cell query that weren't actually consumed anywhere in the code. Sometime later i discovered the Cell to stay in ` state indefinitely, although on the network tab i could see all graphql queries came back fine.
After some more investigation it turned out the underlying issue was Uncaught Invariant Violation: Missing field '…' while extracting keyFields from { … } being thrown by apollo (which after a little digesting made sense to me), leading to the cell somehow never reaching the success state – or in this case: the correct behavior would have been to render the <Error /> component.
How do we reproduce the bug?
My issue was triggered by leaving out the apollo keyField responsible for network caching… however i believe there may be other errors that simply are not caught properly in the cell component.
Not sure, but may be worth checking first if this isn't the result of a race condition due to re-instantiated apollo clients as described in #11602, so first check out @justinadkins' fix branch from #11699 and see if this issue persists with that fix.
What's not working?
I recently cleaned up some code in our project and removed all fields from a Cell query that weren't actually consumed anywhere in the code. Sometime later i discovered the Cell to stay in ` state indefinitely, although on the network tab i could see all graphql queries came back fine.
After some more investigation it turned out the underlying issue was
Uncaught Invariant Violation: Missing field '…' while extracting keyFields from { … }
being thrown by apollo (which after a little digesting made sense to me), leading to the cell somehow never reaching the success state – or in this case: the correct behavior would have been to render the<Error />
component.How do we reproduce the bug?
My issue was triggered by leaving out the apollo keyField responsible for network caching… however i believe there may be other errors that simply are not caught properly in the cell component.
What's your environment? (If it applies)
Are you interested in working on this?
The text was updated successfully, but these errors were encountered: