How can I catch a type error at runtime? #869
Unanswered
special-character
asked this question in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I am working on catching a developer error where we accidentally had a mis-match between our client and server. The client had updated code that requested a type from an endpoint that had it's type changed.
This was the error:
The endpoint still had the
Boolean
field but our resolver was requesting data for a full user.I can repro this level of error by returning the wrong type.
The try catch is never hit b/c the error happens before it makes it here. Even my error middleware is not hit b/c the type error happens before it makes it that far.
Beta Was this translation helpful? Give feedback.
All reactions