Skip to content

Remove Python 3.8 exclusive branches from third-party packages #13772

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

Merged
merged 1 commit into from
Apr 2, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions stubs/icalendar/icalendar/timezone/zoneinfo.pyi
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
import datetime
import sys
from typing import Final, Literal
from zoneinfo import ZoneInfo

from dateutil.rrule import rrule, rruleset

if sys.version_info >= (3, 9):
from zoneinfo import ZoneInfo
else:
from backports.zoneinfo import ZoneInfo

from ..cal import Timezone
from ..prop import vRecur
from .provider import TZProvider
Expand Down
22 changes: 10 additions & 12 deletions stubs/mypy-extensions/mypy_extensions.pyi
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import abc
import sys
from _collections_abc import dict_items, dict_keys, dict_values
from _typeshed import IdentityFunction, Unused
from collections.abc import Mapping
Expand Down Expand Up @@ -27,17 +26,16 @@ class _TypedDict(Mapping[str, object], metaclass=abc.ABCMeta):
def keys(self) -> dict_keys[str, object]: ...
def values(self) -> dict_values[str, object]: ...
def __delitem__(self, k: Never) -> None: ...
if sys.version_info >= (3, 9):
@overload
def __or__(self, value: Self, /) -> Self: ...
@overload
def __or__(self, value: dict[str, Any], /) -> dict[str, object]: ...
@overload
def __ror__(self, value: Self, /) -> Self: ...
@overload
def __ror__(self, value: dict[str, Any], /) -> dict[str, object]: ...
# supposedly incompatible definitions of `__or__` and `__ior__`:
def __ior__(self, value: Self, /) -> Self: ... # type: ignore[misc]
@overload
def __or__(self, value: Self, /) -> Self: ...
@overload
def __or__(self, value: dict[str, Any], /) -> dict[str, object]: ...
@overload
def __ror__(self, value: Self, /) -> Self: ...
@overload
def __ror__(self, value: dict[str, Any], /) -> dict[str, object]: ...
# supposedly incompatible definitions of `__or__` and `__ior__`:
def __ior__(self, value: Self, /) -> Self: ... # type: ignore[misc]

def TypedDict(typename: str, fields: dict[str, type[Any]], total: bool = ...) -> type[dict[str, Any]]: ...
@overload
Expand Down
11 changes: 3 additions & 8 deletions stubs/regex/regex/regex.pyi
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import sys
from _typeshed import ReadableBuffer, Unused
from collections.abc import Callable, Mapping
from types import GenericAlias
from typing import Any, AnyStr, Generic, Literal, TypeVar, final, overload
from typing_extensions import Self

from . import _regex
from ._regex_core import *

if sys.version_info >= (3, 9):
from types import GenericAlias

_T = TypeVar("_T")

__version__: str
Expand Down Expand Up @@ -569,8 +566,7 @@ class Pattern(Generic[AnyStr]):
) -> _regex.Scanner[bytes]: ...
def __copy__(self) -> Self: ...
def __deepcopy__(self, memo: Unused, /) -> Self: ...
if sys.version_info >= (3, 9):
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...

@final
class Match(Generic[AnyStr]):
Expand Down Expand Up @@ -648,5 +644,4 @@ class Match(Generic[AnyStr]):
def __getitem__(self, key: int | str, /) -> AnyStr | Any: ...
def __copy__(self) -> Self: ...
def __deepcopy__(self, memo: Unused, /) -> Self: ...
if sys.version_info >= (3, 9):
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...
7 changes: 1 addition & 6 deletions stubs/six/six/moves/_dummy_thread.pyi
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
import sys

if sys.version_info >= (3, 9):
from _thread import *
else:
from _dummy_thread import *
from _thread import *