Hi all, just a small one: The line https://github.com/graphql-python/graphql-server/blob/2d5ac9539307d6db22b3364a61063e050c3f20b9/src/graphql_server/flask/views.py#L145 creates the context with `operationName` but the template https://github.com/graphql-python/graphql-server/blob/2d5ac9539307d6db22b3364a61063e050c3f20b9/src/graphql_server/static/graphiql.html#L199 expects `operation_name`. Probably `request_data.to_template_context()` is meant to be used which does use `operation_name`: https://github.com/graphql-python/graphql-server/blob/2d5ac9539307d6db22b3364a61063e050c3f20b9/src/graphql_server/http/__init__.py#L74 Thanks!
Activity
tking2 commentedon Nov 3, 2025
Spotting bigger issues than just the
operation_namevariable.https://github.com/graphql-python/graphql-server/blob/main/src/graphql_server/static/graphiql.html#L187C42-L187C55
locationQueryhas been removed from this file, but we're still seeing a reference here.I'm pinned to 3.0.0b7 while 3.0.0 is still unstable.
jahs commentedon Nov 4, 2025
Hi, thanks for looking at this. Also related is I get an issue with html escaping when using
to_template_context(), as ingraphql-server/src/graphql_server/static/graphiql.html
Line 197 in 2d5ac95
"". Can be fixed withmarkupsafe.Markup(tojson(....atgraphql-server/src/graphql_server/http/__init__.py
Line 71 in 2d5ac95
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
Fix GraphiQL IDE rendering (graphql-python#137)
leonardwellthy commentedon Feb 10, 2026
I submitted a PR to fix these issues: #138 but I have no idea what it takes to get a review!