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
TLDR: We should support a way (possibly via a hook on the Charlatan object) to output additional logs on things like attempted matches and failed matches such that the end user doesn't need to add break-points to debug Charlatan or pull it locally. The default verbosity would remain, so this would be opt-in per Charlatan instance.
Sam's comment:
I feel ya on the struggle of making this readable for gql or other nuanced requests.
Two thoughts:
We could probably do something to include the query string here in addition to just the path. That won't help for gql unless we make some tweaks to clients to include the operation name in the query string. Which would be really useful
We could add a hook on Charlatan to allow you to customize how the request prints out for this debugging use case with a solid default. Then consumers can do whatever makes sense to them to make the failed match on the request easier to interpret. Like in the case of gql maybe you can parse the operation name from the body instead of using the whole body. Not sure of a great name for this. Maybe requestDebugFormatter? Naming this is hard haha
TLDR: We should support a way (possibly via a hook on the
Charlatan
object) to output additional logs on things like attempted matches and failed matches such that the end user doesn't need to add break-points to debug Charlatan or pull it locally. The default verbosity would remain, so this would be opt-in perCharlatan
instance.Sam's comment:
I feel ya on the struggle of making this readable for gql or other nuanced requests.
Two thoughts:
requestDebugFormatter
? Naming this is hard hahaWhat do you think?
Originally posted by @samandmoore in #26 (comment)
The text was updated successfully, but these errors were encountered: