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

Method __call__

src/werkzeug/debug/repr.py:63–78  ·  view source on GitHub ↗
(self, topic: t.Any | None = None)

Source from the content-addressed store, hash-verified

61 return "Type help(object) for help about object."
62
63 def __call__(self, topic: t.Any | None = None) -> None:
64 if topic is None:
65 sys.stdout._write(f"<span class=help>{self!r}</span>") # type: ignore
66 return
67 import pydoc
68
69 pydoc.help(topic)
70 rv = sys.stdout.reset() # type: ignore
71 paragraphs = _paragraph_re.split(rv)
72 if len(paragraphs) > 1:
73 title = paragraphs[0]
74 text = "\n\n".join(paragraphs[1:])
75 else:
76 title = "Help"
77 text = paragraphs[0]
78 sys.stdout._write(HELP_HTML % {"title": title, "text": text}) # type: ignore
79
80
81helper = _Helper()

Callers

nothing calls this directly

Calls 2

_writeMethod · 0.80
resetMethod · 0.80

Tested by

no test coverage detected