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
Describe the bug
It looks like variables are coerced twice during an execution using graphql-java 16.2, once in execute and once in validateFieldsAndArguments. This breaks e.g. enums with non-default names.
I just noticed that we're not using the field validation correctly. Instead of using SimpleFieldValidation and adding rules, we were using a separate FieldValidationInstrumentation for each rule and chaining them together using ChainedInstrumentation. Fixing that will probably also fix this issue.
Thank you for your help!
Describe the bug
It looks like variables are coerced twice during an execution using graphql-java 16.2, once in
execute
and once invalidateFieldsAndArguments
. This breaks e.g. enums with non-default names.Variables are first coerced here, then added to the execution context.
In
FieldValidationSupport
, theQueryTraverser
is initialized with those variables from the execution context and coerces them again here.To Reproduce
If you have an enum value defined like this
the first coercion works correctly, but the second one fails.
The text was updated successfully, but these errors were encountered: