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
Current behaviour:
When using the depth_limit_validator (docs), an invalid query can lead to a KeyError being thrown (from here), which usually results in the API returning a 500 server error.
To reproduce:
Add the depth_limit_validator to the validation_rules in your GraphQLView.
Execute a query with an undefined fragment, i.e. something like:
Expected behaviour:
A standard validation error response, like:
{
"errors": [
{
"message": "Unknown fragment 'undefinedFragment'.",
"locations": [
{
"line": x,
"column": y
}
]
}
]
}
Since this is something that's caught by the standard validators, depth_limit_validator should probably just skip such errors. Or, do whatever the other validators do when they hit an "unrelated" error.
Environment:
Version: 3.3
Platform: n/a
The text was updated successfully, but these errors were encountered:
Current behaviour:
When using the
depth_limit_validator
(docs), an invalid query can lead to aKeyError
being thrown (from here), which usually results in the API returning a 500 server error.To reproduce:
depth_limit_validator
to thevalidation_rules
in yourGraphQLView
.Expected behaviour:
A standard validation error response, like:
Since this is something that's caught by the standard validators,
depth_limit_validator
should probably just skip such errors. Or, do whatever the other validators do when they hit an "unrelated" error.Environment:
The text was updated successfully, but these errors were encountered: