Closed
Description
The parsing and validation of graphql queries is doubled up!
Using the following versions:
graphql-core==3.1.4
graphene==3.0.0b7
graphene-django==3.0.0b7
- graphene_django.views.GraphQLView. execute_graphql_request parses and validates the query but then passes the string version of the query to `graphene
- graphene.Schema.execute calls
graphql.graphql_sync
- graphql.graphql_sync calls
grapqhl.graphql.graphql_impl
- graphql.graphql.graphql_impl calls
parse
andvalidate
again.
My knowledge of these libraries is pretty minimal but I noticed this as our largest queries can take ~300ms or so of parsing + validating, and even after introducing a cache inside a subclass of graphene_django.views.GraphQLView
I was still getting a delay on execution.
I would make a pull request, but I think the approach probably requires a discussion first!