Skip to content

Commit f1d1ff3

Browse files
committed
chore(mypy): fix coroutine response not being ready to subscribe
1 parent 306bfd3 commit f1d1ff3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/event_handler_graphql/src/assert_async_graphql_response_module.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ class Todo(TypedDict, total=False):
2525
async def list_todos() -> list[Todo]:
2626
async with aiohttp.ClientSession(trace_configs=[aiohttp_trace_config()]) as session:
2727
async with session.get("https://jsonplaceholder.typicode.com/todos") as resp:
28-
# first two results to demo assertion
29-
return await resp.json()[:2]
28+
result: list[Todo] = await resp.json()
29+
return result[:2] # first two results to demo assertion
3030

3131

3232
@logger.inject_lambda_context(correlation_id_path=correlation_paths.APPSYNC_RESOLVER)

0 commit comments

Comments
 (0)