log
log copied to clipboard
json handler: Unsupported type serializing oauth error
One of the errors dispatched by the oauth2 library contains a http.Response
which causes the following error:
error logging: json: unsupported type: func() (io.ReadCloser, error)
This feels like something WithError(err)
should handle gracefully, otherwise knowledge of underlying error types needs to be propagated throughout the code.
I'm happy to submit a patch, but not sure what the best solution for this is. Guidance welcome.
Hmm sounds like it's just not serializable as JSON, I don't think there's much we could do here, but otherwise I agree, seems like it was just a weird choice for the error's concrete type. I'd open an issue with them as well