I\'m currently trying to right align the logging level field in my Python logger so that output such as:
[2011-10-14 13:47:51] [DEBUG] --- starting... (smtphandl
Like this:
logging.Formatter("[%(asctime)s] [%(levelname)8s] --- %(message)s (%(filename)s:%(lineno)s)", "%Y-%m-%d %H:%M:%S")
Try with this format line :
logging.Formatter("[%(asctime)s] [%(levelname)8s] --- %(message)s (%(filename)s:%(lineno)s)", "%Y-%m-%d %H:%M:%S")
python logger formatter use the standard python string formatting rules