mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 05:24:52 +08:00
Bump tzlocal to 5.0 (#10183)
This commit is contained in:
@@ -1,2 +1,2 @@
|
||||
version = "4.3"
|
||||
version = "5.0"
|
||||
requires = ["types-pytz"]
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
from pytz import BaseTzInfo
|
||||
from tzlocal.utils import assert_tz_offset
|
||||
|
||||
__all__ = ["get_localzone", "get_localzone_name", "reload_localzone", "assert_tz_offset"]
|
||||
|
||||
def reload_localzone() -> None: ...
|
||||
def get_localzone() -> BaseTzInfo: ...
|
||||
|
||||
@@ -1,16 +1,4 @@
|
||||
import datetime
|
||||
import sys
|
||||
|
||||
import pytz
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
import zoneinfo
|
||||
|
||||
class ZoneInfoNotFoundError(pytz.UnknownTimeZoneError, zoneinfo.ZoneInfoNotFoundError): ...
|
||||
|
||||
else:
|
||||
class ZoneInfoNotFoundError(pytz.UnknownTimeZoneError): ...
|
||||
|
||||
def get_system_offset() -> int: ...
|
||||
def get_tz_offset(tz: datetime.tzinfo) -> int: ...
|
||||
def assert_tz_offset(tz: datetime.tzinfo) -> None: ...
|
||||
def assert_tz_offset(tz: datetime.tzinfo, error: bool = True) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user