summaryrefslogtreecommitdiffstats
path: root/Lib/wsgiref
diff options
context:
space:
mode:
authorShantanu <12621235+hauntsaninja@users.noreply.github.com>2022-07-21 20:26:04 (GMT)
committerGitHub <noreply@github.com>2022-07-21 20:26:04 (GMT)
commitb4378948a066821ce5147940ce3c1a80bc018b3c (patch)
tree72176b83afbc4528f776ffaff0d84da1ce0ea595 /Lib/wsgiref
parent936f71e5d4f50f2238b0320d44f7fb5f88e39809 (diff)
downloadcpython-b4378948a066821ce5147940ce3c1a80bc018b3c.zip
cpython-b4378948a066821ce5147940ce3c1a80bc018b3c.tar.gz
cpython-b4378948a066821ce5147940ce3c1a80bc018b3c.tar.bz2
gh-95105: Return Iterator from wsgiref.types.InputStream.__iter__ (#95106)
Diffstat (limited to 'Lib/wsgiref')
-rw-r--r--Lib/wsgiref/types.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/wsgiref/types.py b/Lib/wsgiref/types.py
index 9e74a6c..ef0aead 100644
--- a/Lib/wsgiref/types.py
+++ b/Lib/wsgiref/types.py
@@ -1,6 +1,6 @@
"""WSGI-related types for static type checking"""
-from collections.abc import Callable, Iterable
+from collections.abc import Callable, Iterable, Iterator
from types import TracebackType
from typing import Any, Protocol, TypeAlias
@@ -35,7 +35,7 @@ class InputStream(Protocol):
def read(self, size: int = ..., /) -> bytes: ...
def readline(self, size: int = ..., /) -> bytes: ...
def readlines(self, hint: int = ..., /) -> list[bytes]: ...
- def __iter__(self) -> Iterable[bytes]: ...
+ def __iter__(self) -> Iterator[bytes]: ...
class ErrorStream(Protocol):
"""WSGI error stream as defined in PEP 3333"""