Skip to content

Commit e96d8eb

Browse files
author
Lukasz Langa
committed
Temporary workaround for werkzeug/issues#1052
Starting with python/mypy#2521 mypy is performing stricter function signature checks. This makes the stubs diverge from the actual implementation but makes the stubs internally consistent. Since this is an actual typing issue in the base implementation, we need to defer to the original authors to fix it.
1 parent 27f4185 commit e96d8eb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

third_party/2/werkzeug/wrappers.pyi

+2-2
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ class BaseResponse:
9494
def close(self): ...
9595
def __enter__(self): ...
9696
def __exit__(self, exc_type, exc_value, tb): ...
97-
def freeze(self, **kwargs): ...
97+
def freeze(self): ...
9898
def get_wsgi_headers(self, environ): ...
9999
def get_app_iter(self, environ): ...
100100
def get_wsgi_response(self, environ): ...
@@ -191,4 +191,4 @@ class WWWAuthenticateMixin:
191191

192192
class Request(BaseRequest, AcceptMixin, ETagRequestMixin, UserAgentMixin, AuthorizationMixin, CommonRequestDescriptorsMixin): ...
193193
class PlainRequest(StreamOnlyMixin, Request): ...
194-
class Response(BaseResponse, ETagResponseMixin, ResponseStreamMixin, CommonResponseDescriptorsMixin, WWWAuthenticateMixin): ...
194+
class Response(ETagResponseMixin, BaseResponse, ResponseStreamMixin, CommonResponseDescriptorsMixin, WWWAuthenticateMixin): ... # FIXME: This is invalid but works around https://github.com/pallets/werkzeug/issues/1052

0 commit comments

Comments
 (0)