MCPcopy
hub / github.com/pallets/werkzeug / get_headers

Method get_headers

src/werkzeug/exceptions.py:389–397  ·  view source on GitHub ↗
(
        self,
        environ: WSGIEnvironment | None = None,
        scope: dict[str, t.Any] | None = None,
    )

Source from the content-addressed store, hash-verified

387 self.valid_methods = valid_methods
388
389 def get_headers(
390 self,
391 environ: WSGIEnvironment | None = None,
392 scope: dict[str, t.Any] | None = None,
393 ) -> list[tuple[str, str]]:
394 headers = super().get_headers(environ, scope)
395 if self.valid_methods:
396 headers.append(("Allow", ", ".join(self.valid_methods)))
397 return headers
398
399
400class NotAcceptable(HTTPException):

Callers 1

Calls 2

appendMethod · 0.80
get_headersMethod · 0.45

Tested by 1