picologging icon indicating copy to clipboard operation
picologging copied to clipboard

Python code crashes if I use %f in datefmt

Open nramprasad85 opened this issue 1 year ago • 4 comments

The code below crashes. But if I remove %f it works. My application is a time critical one and the microsecond info is most required. lacking %f is a showstopper for me. Please let me know once it is enabled, will then start using 🙏

import picologging as logging
logging.basicConfig(level=logging.DEBUG, format='%(asctime)s - %(levelname)s - %(message)s', datefmt='%Y-%m-%d %H:%M:%S.%f')
logger=logging.getLogger()
print("starting")
logger.info("test")
print("done")

nramprasad85 avatar Oct 11 '23 05:10 nramprasad85