[go: up one dir, main page]

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

Update various references to deprecated type aliases in docs #17829

Merged
merged 4 commits into from
Sep 26, 2024

Conversation

JukkaL
Copy link
Collaborator
@JukkaL JukkaL commented Sep 25, 2024

Use collections.abc.Iterable, for example, instead of typing.Iterable, unless we are discussing support for older Python versions. The latter has been deprecated since Python 3.9. Also update a few other out-of-date things that I happened to notice.

Part of the motivation is that Python 3.8 will reach end of life in October, so we can soon start mostly assuming that users are on 3.9 or newer (even if we'll continue supporting 3.8 for a while still).

Use `collections.abc.Iterable`, for example, instead of `typing.Iterable`,
unless we are discussing support for older Python versions. The latter
has been deprecated since Python 3.9. Also update a few other out-of-date
things that I happened to notice.
@@ -88,7 +88,8 @@ Functions

.. code-block:: python

from typing import Callable, Iterator, Union, Optional
from collections.abc import Iterator
from typing import Callable, Union, Optional
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Callable can also be imported from collections.abc

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, updated imports of Callables in examples as well.

docs/source/runtime_troubles.rst Outdated Show resolved Hide resolved
docs/source/runtime_troubles.rst Outdated Show resolved Hide resolved
@JukkaL JukkaL merged commit 0dfb718 into master Sep 26, 2024
2 checks passed
@JukkaL JukkaL deleted the doc-collections-abc branch September 26, 2024 10:19
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