Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d086488

Browse filesBrowse files
authored
Revert "Use import instead of type alias in email/message.pyi" (#7548)
Let's see if this is fixed in mypy 0.942. This reverts the changes made in #7022, which was a hack to fix #7019
1 parent 4b63f34 commit d086488
Copy full SHA for d086488

File tree

Expand file treeCollapse file tree

1 file changed

+2
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-3
lines changed

‎stdlib/email/message.pyi

Copy file name to clipboardExpand all lines: stdlib/email/message.pyi
+2-3Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@ from email.charset import Charset
22
from email.contentmanager import ContentManager
33
from email.errors import MessageDefect
44
from email.policy import Policy
5-
6-
# using a type alias ("_HeaderType = Any") breaks mypy, who knows why
7-
from typing import Any, Any as _HeaderType, Generator, Iterator, Sequence, TypeVar, Union
5+
from typing import Any, Generator, Iterator, Sequence, TypeVar, Union
86

97
__all__ = ["Message", "EmailMessage"]
108

@@ -14,6 +12,7 @@ _PayloadType = list[Message] | str | bytes
1412
_CharsetType = Charset | str | None
1513
_ParamsType = Union[str, None, tuple[str, str | None, str]]
1614
_ParamType = Union[str, tuple[str | None, str | None, str]]
15+
_HeaderType = Any
1716

1817
class Message:
1918
policy: Policy # undocumented

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.