We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1195fd3 commit cf7209bCopy full SHA for cf7209b
sebs/color.py
@@ -12,6 +12,10 @@ class Colors:
12
class ColoredPrinter:
13
@staticmethod
14
def print(color, logging_instance, message):
15
+ # Print the colored message by click
16
timestamp = datetime.datetime.now().strftime("%H:%M:%S")
- logging_instance.info(message)
17
- click.echo(f"{color}{Colors.BOLD}[{timestamp}]{Colors.END} {message}")
+ click.echo(f"{color}{Colors.BOLD}[{timestamp}]{Colors.END} {message}")
18
+
19
+ # Log the message but don't propagate to stdout
20
+ logging_instance.propagate = False
21
+ logging_instance.info(message)
0 commit comments