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

Use Final = ... instead of Final[Literal] #11623

Merged
merged 1 commit into from
Mar 17, 2024
Merged
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
Use Final = ... instead of Final[Literal]
  • Loading branch information
srittau committed Mar 17, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit d98ff1f113a59e98432fd0f67179476749f562c5
2 changes: 1 addition & 1 deletion stubs/croniter/croniter/croniter.pyi
Original file line number Diff line number Diff line change
@@ -36,7 +36,7 @@ class CroniterNotAlphaError(CroniterError): ...
def datetime_to_timestamp(d: datetime.datetime) -> float: ...

class croniter(Iterator[Any]):
MONTHS_IN_YEAR: Final[Literal[12]]
MONTHS_IN_YEAR: Final = 12
RANGES: Final[tuple[tuple[int, int], tuple[int, int], tuple[int, int], tuple[int, int], tuple[int, int], tuple[int, int]]]
DAYS: Final[
tuple[
8 changes: 4 additions & 4 deletions stubs/pika/pika/compat.pyi
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@ from abc import ABCMeta
from collections.abc import ItemsView, Mapping, ValuesView
from io import StringIO as StringIO
from re import Pattern
from typing import Any, Final, Literal, SupportsIndex, TypeVar
from typing import Any, Final, SupportsIndex, TypeVar
from typing_extensions import TypeGuard
from urllib.parse import parse_qs, quote, unquote, urlencode as urlencode, urlparse as urlparse

@@ -13,8 +13,8 @@ url_quote = quote
url_unquote = unquote
url_parse_qs = parse_qs

PY2: Final[Literal[False]]
PY3: Final[Literal[True]]
PY2: Final = False
PY3: Final = True
RE_NUM: Final[Pattern[str]]
ON_LINUX: Final[bool]
ON_OSX: Final[bool]
@@ -45,5 +45,5 @@ def to_digit(value: str) -> int: ...
def get_linux_version(release_str: str) -> tuple[int, int, int]: ...

HAVE_SIGNAL: Final[bool]
EINTR_IS_EXPOSED: Final[Literal[False]]
EINTR_IS_EXPOSED: Final = False
LINUX_VERSION: tuple[int, int, int] | None