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
The current GraphiQl interface and WebGraphQlRequest are not compatible
spring-graphql 1.1.3 retrieved the key 'operationName' from the post body: getKey("operationName", body) [in the call to super on line 87]
whilst the current implementation retrieves 'operation': Object value = body.get("operation"); [in the getOperation method on line 108]
GraphiQl sends a json body containing 'operationName' and 'query' keys and with the current version that results in a
"graphql.execution.UnknownOperationException: Must provide operation name if query contains multiple operations." when sending a document with multiple queries.
I think operationName is the correct name looking at graphql.org, if so the fix would be in retrieving the correct key from the body, otherwise an update to the graphiql javascript (and a change to include that version in the graphiql.html) is probably the solution. (Supporting two keys in case one of the two is empty does not sound like a good solution to me)
Reproducable by starting a project with spring-graphql-1.2.1 and an enabled graphiql interface (spring.graphql.graphiql.enabled: true) and a schema and pasting a simple schema query in the left pane:
Uh oh!
There was an error while loading. Please reload this page.
The current GraphiQl interface and WebGraphQlRequest are not compatible
spring-graphql 1.1.3 retrieved the key 'operationName' from the post body:
getKey("operationName", body)
[in the call to super on line 87]whilst the current implementation retrieves 'operation':
Object value = body.get("operation");
[in the getOperation method on line 108]GraphiQl sends a json body containing 'operationName' and 'query' keys and with the current version that results in a
"
graphql.execution.UnknownOperationException: Must provide operation name if query contains multiple operations.
" when sending a document with multiple queries.I think operationName is the correct name looking at graphql.org, if so the fix would be in retrieving the correct key from the body, otherwise an update to the graphiql javascript (and a change to include that version in the graphiql.html) is probably the solution. (Supporting two keys in case one of the two is empty does not sound like a good solution to me)
Reproducable by starting a project with spring-graphql-1.2.1 and an enabled graphiql interface (spring.graphql.graphiql.enabled: true) and a schema and pasting a simple schema query in the left pane:
then choosing either of the queries in the dropdown that appears when clicking the 'play' button.
The text was updated successfully, but these errors were encountered: