Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blocking_connection: Fix consume() return type #1

Merged
merged 3 commits into from
Jan 16, 2022
Merged

blocking_connection: Fix consume() return type #1

merged 3 commits into from
Jan 16, 2022

Conversation

baodrate
Copy link
Owner

@baodrate baodrate commented Jan 15, 2022

Fixes hahow/pika-stubs/issues/3.

Signed-off-by: Anders Kaseorg [email protected]


From hahow/pika-stubs/pull/4

baodrate pushed a commit that referenced this pull request Jan 16, 2022
Mypy supports new Python features in stubs even when running on older
Python versions. And at runtime, by definition, type stubs are not
used or even imported at all. So there is no reason to restrict the
Python version.

Fixes #1.

Signed-off-by: Anders Kaseorg <[email protected]>
baodrate pushed a commit that referenced this pull request Jan 16, 2022
Mypy supports new Python features in stubs even when running on older
Python versions. And at runtime, by definition, type stubs are not
used or even imported at all. So there is no reason to restrict the
Python version.

Fixes #1.

Signed-off-by: Anders Kaseorg <[email protected]>
The return is either a tuple with all fields or a tuple with all None.
Remove the semantic ambiguity that allows for e.g.
    -> Tuple[None, spec.BasicProperties, None]
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.

Incorrect return type of consume() method.
2 participants