-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
ResolverError field in QueryError not set and public errors in general #38
Comments
I guess you are expecting it to work a bit more like this? It would let you put a String() method on your error for display to the user? |
Yes exactly. Storing the
and use Let me know what you think, I could try to make a PR for this once we decide what approach to go for. |
I really like this idea. Leave the error as an Its probably a fair bit of work though. |
Alright, I'll see if I can make a PR this week:
|
I see that the
ResolverError
field onQueryError
is not set. What is the plan for this? TheBuilder
for errors currently only takes the error message and creates aQueryError
from that.I was a bit surprised to see that by default the generated execution context drops the original error and exposes the raw message error in the GraphQL response. What are your thoughts for this?
I can imagine one wants to be able to control how errors thrown from the resolvers are rendered. I'm using a custom written HTTP handler and would like to be able to log the original errors. Do you think it's better to do logging etc. of the errors inside the resolvers and return a custom 'public' error?
Thanks for the awesome lib! Please let us know if there are any areas where you could use some help!
The text was updated successfully, but these errors were encountered: