[stdlib] Updates for Python 3.13.12 and 3.14.3 (#15371)

This commit is contained in:
Semyon Moroz
2026-02-04 18:21:43 -08:00
committed by GitHub
parent 516eed0d5f
commit e56ab929fd
6 changed files with 51 additions and 1 deletions
+12
View File
@@ -1,3 +1,4 @@
import sys
import types
from collections.abc import Iterable, Mapping
from datetime import datetime as _datetime
@@ -137,6 +138,17 @@ class MessageIDHeader:
@staticmethod
def value_parser(value: str) -> MessageID: ...
if sys.version_info >= (3, 13):
from email._header_value_parser import MessageIDList
# Added in Python 3.13.12, 3.14.3
class ReferencesHeader:
max_count: ClassVar[Literal[1]]
@classmethod
def parse(cls, value: str, kwds: dict[str, Any]) -> None: ...
@staticmethod
def value_parser(value: str) -> MessageIDList: ...
@type_check_only
class _HeaderParser(Protocol):
max_count: ClassVar[Literal[1] | None]