MCPcopy Create free account
hub / github.com/datapane/datapane / display_msg

Function display_msg

python-client/src/datapane/client/utils.py:149–160  ·  view source on GitHub ↗
(text: str, **params: str)

Source from the content-addressed store, hash-verified

147
148
149def display_msg(text: str, **params: str):
150 from datapane.ipython.environment import get_environment
151
152 environment = get_environment()
153
154 msg = MarkdownFormatter(environment.is_notebook_environment).format(text, **params)
155 if environment.is_notebook_environment:
156 from IPython.display import Markdown, display
157
158 display(Markdown(msg))
159 else:
160 print(msg)
161
162
163############################################################

Callers 5

cells_to_blocksFunction · 0.90
_render_traceback_Method · 0.90
guess_templateFunction · 0.90
__call__Method · 0.90
__call__Method · 0.90

Calls 3

get_environmentFunction · 0.90
MarkdownFormatterClass · 0.85
formatMethod · 0.80

Tested by

no test coverage detected