MCPcopy Index your code
hub / github.com/dbcli/mycli / log_output

Method log_output

mycli/output.py:78–83  ·  view source on GitHub ↗

Log the output in the audit log, if it's enabled.

(self, output: str | AnyFormattedText)

Source from the content-addressed store, hash-verified

76 self.logfile.write("\n")
77
78 def log_output(self, output: str | AnyFormattedText) -> None:
79 """Log the output in the audit log, if it's enabled."""
80 if isinstance(output, (ANSI, HTML, FormattedText)):
81 output = to_plain_text(output)
82 if isinstance(self.logfile, TextIOWrapper):
83 click.echo(output, file=self.logfile)
84
85 def echo(self, s: str, **kwargs) -> None:
86 """Print a message to stdout."""

Callers 3

output_timingMethod · 0.95
echoMethod · 0.95
outputMethod · 0.95

Calls 1

echoMethod · 0.45

Tested by

no test coverage detected