File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -161,14 +161,16 @@ def error(self) -> Optional[Exception]:
161161 return self .__error
162162
163163 @property
164- def headers (self ) -> Optional [Dict [ str , Any ] ]:
164+ def headers (self ) -> Optional [Headers ]:
165165 """
166166 The HTTP response headers from the failed connection, if available.
167167
168168 This property returns headers when the error is an exception that includes them,
169169 such as :class:`.HTTPStatusError` or :class:`.HTTPContentTypeError`. For other
170170 error types or when the stream ended normally, this returns ``None``.
171171
172+ Header name lookups are case-insensitive per RFC 7230.
173+
172174 :return: the response headers, or ``None`` if not available
173175 """
174176 if isinstance (self .__error , ExceptionWithHeaders ):
You can’t perform that action at this time.
0 commit comments