Skip to content

Fix Tuple type hint #18

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

Closed
wants to merge 1 commit into from
Closed

Conversation

PhillSimonds
Copy link

The type hint for the probe async coroutine definition was 'tuple' instead of 'Tuple'. This caused python 3.8.10 to fail to compile the code.

The type hint for the probe async coroutine definition was 'tuple' instead of 'Tuple'. This caused python 3.8.10 to fail to compile the code.
@ramalho
Copy link
Member

ramalho commented Dec 27, 2021

Thank you for raising this issue, but I will leave the code as is.

The book targets Python 3.9 and 3.10. There are numerous sections in the book focused on type hints that mention the issue of having to import Tuple from typing in older versions of Python, instead of using just tuple as Python >= 3.9 supports.

I want to encourage readers to drop the redundant imports from typing as soon as possible. They are already deprecated and will be removed in a few years.

Therefore, I will leave the code as is.

@ramalho ramalho closed this Dec 27, 2021
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.

3 participants