Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Execute should return an awaitable with AsyncioExecutor

Open
#78 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
api

Research direction

Start in graphql.execution.execute.execute and inspect how AsyncioExecutor uses wait_until_finished, then compare the executor integration points relevant to TwistedExecutor. Define how the executor supplies the post-data callback and how compatibility is preserved. Done means AsyncioExecutor can return an awaitable usable with await execute while existing uses remain supported.

Written by the indexing model from the issue text.

Description

The current graphql.execution.execute.execute implementation forces AsyncioExecutor to use loop.run_until_complete in wait_until_finished. This is a bit ugly.

It would be better to let the executor decide what is returned from the execute method. It can be given a function to call after the data is ready as an argument.

With this AsyncioExecutor could return an awaitable and execute would be used as one would expect

result = await execute(schema, ast, executor=AsyncioExecutor())

It could even have an argument to get the new way to keep compatibility with existing uses.

This would also make TwistedExecutor much easier to implement.

Dominant language
Python
Stars
371
Forks
175
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from graphql-python/graphql-core-legacy

All issues in graphql-python/graphql-core-legacy

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.