Open yechielb2000 opened 2 hours ago
Hi.
This is because the format
must also include color markups like "<green></green>"
or "<red></red>"
for example. See documentation here: The color markups.
Also, you may take a look at this: Why are my logs not colored?.
The following code should work:
import sys
from loguru import logger
logger.remove(0)
logger.add(sys.stdout, colorize=True, format='<green>{time}</> <level>{message}</>')
logger.info('this is a message')
Doesn't actually print with colors (specificly when also using
foarmt
flag)