Use RichHighlighter for console
MODIFY
plextraktsync/console.py
plextraktsync/console.py
-from rich import get_console
+from rich.console import Console
-console = get_console()
+from plextraktsync.rich_addons import RichHighlighter
+
+console = Console(highlighter=RichHighlighter())
print = console.print

MODIFY
plextraktsync/factory.py
plextraktsync/factory.py
from deprecated import deprecated
from plextraktsync.decorators.memoize import memoize
+from plextraktsync.rich_addons import RichHighlighter
class Factory:
@@ -120,12 +121,11 @@ def walker(self):
@memoize
def console_logger(self):
- from rich.highlighter import ReprHighlighter
from rich.logging import RichHandler
from plextraktsync.console import console
- handler = RichHandler(console=console, show_time=False, show_path=False, highlighter=ReprHighlighter())
+ handler = RichHandler(console=console, show_time=False, show_path=False, highlighter=RichHighlighter())
return handler

Use RichHighlighter for console