MCPcopy
hub / github.com/Textualize/rich / get_console

Function get_console

rich/__init__.py:23–36  ·  rich/__init__.py::get_console

Get a global :class:`~rich.console.Console` instance. This function is used when Rich requires a Console, and hasn't been explicitly given one. Returns: Console: A console instance.

()

Source from the content-addressed store, hash-verified

21
22
23def get_console() -> class="st">"Console":
24 class="st">"""Get a global :class:`~rich.console.Console` instance. This function is used when Rich requires a Console,
25 and hasn&class="cm">#x27;t been explicitly given one.
26
27 Returns:
28 Console: A console instance.
29 class="st">"""
30 global _console
31 if _console is None:
32 from .console import Console
33
34 _console = Console()
35
36 return _console
37
38
39def reconfigure(*args: Any, **kwargs: Any) -> None:

Callers 13

_ipy_display_hookFunction · 0.90
installFunction · 0.90
pprintFunction · 0.90
_repr_mimebundle_Method · 0.85
printFunction · 0.85
__init__Method · 0.85
__init__Method · 0.85
__init__Method · 0.85
reconfigureFunction · 0.85
printFunction · 0.85
print_jsonFunction · 0.85
inspectFunction · 0.85

Calls 1

ConsoleClass · 0.85

Tested by

no test coverage detected