Skip to content

Fixes redis.asyncio.client: AsyncIterator cannot be async def in stubs. - #8961

Merged
JelleZijlstra merged 1 commit into
python:masterfrom
peterschutt:master
Oct 21, 2022
Merged

JelleZijlstra merged 1 commit into
python:masterfrom
peterschutt:master

Conversation

@peterschutt

Copy link
Copy Markdown
Contributor

Without the yield statement in the method body, these are interpreted by mypy as coroutines that return an AsyncIterator.

Closes #8960

Without the `yield` statement in the method body, these are interpreted by mypy as coroutines that return an `AsyncIterator`.

Closes python#8960
@peterschutt peterschutt changed the title AsyncIterator methods cannot be async def in stubs. Fixes redis.asyncio.client: AsyncIterator cannot be async def in stubs. Oct 21, 2022
@github-actions

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@JelleZijlstra
JelleZijlstra merged commit 25810e1 into python:master Oct 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

False positive: redis.async.PubSub.listen()

2 participants