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

Method get_description

src/werkzeug/exceptions.py:96–108  ·  view source on GitHub ↗

Get the description.

(
        self,
        environ: WSGIEnvironment | None = None,
        scope: dict[str, t.Any] | None = None,
    )

Source from the content-addressed store, hash-verified

94 return HTTP_STATUS_CODES.get(self.code, "Unknown Error") # type: ignore
95
96 def get_description(
97 self,
98 environ: WSGIEnvironment | None = None,
99 scope: dict[str, t.Any] | None = None,
100 ) -> str:
101 """Get the description."""
102 if self.description is None:
103 description = ""
104 else:
105 description = self.description
106
107 description = escape(description).replace("\n", Markup("<br>"))
108 return f"<p>{description}</p>"
109
110 def get_body(
111 self,

Callers 4

get_bodyMethod · 0.95
test_get_descriptionMethod · 0.80
test_response_bodyFunction · 0.80

Calls

no outgoing calls

Tested by 3

test_get_descriptionMethod · 0.64
test_response_bodyFunction · 0.64