graphql / express-graphql

Create a GraphQL HTTP server with Express.
MIT License
6.34k stars 538 forks source link

fix: Allow empty operation names for single queries #768

Closed flovilmart closed 2 years ago

flovilmart commented 3 years ago

Fixes issue #767

linux-foundation-easycla[bot] commented 3 years ago

CLA Signed

The committers are authorized under a signed CLA.

flovilmart commented 2 years ago

@saihaj or @acao , sorry to ping you here, any chance we can move forward with this patch?

saihaj commented 2 years ago

I can’t merge this in but @IvanGoncharov can cut a release for this.

IvanGoncharov commented 2 years ago

@flovilmart Did you report this issue to graphql-go? GraphQL spec doesn't have any special treatment for the empty string as operationName: https://spec.graphql.org/draft/#sec-Executing-Requests So I don't think it's appropriate to merge this PR.

flovilmart commented 2 years ago

Thanks @IvanGoncharov, after reading the spec, it seems that the go implementation is indeed not following the specification regarding empty operation names.

I’ve raised the issue here: https://github.com/graphql-go/graphql/issues/616