Tag: logging
-
Simple logging with rotation and custom format in Python
Sometimes I find myself having to write a short Python script with proper logging capabilities. This code snippet demonstrates how to do use Python’s official logging module using very few lines but still with all these features in: basicConfig log rotation formating The following lines are interesting: ‘/path/to/log/file.log’ -> lets you specify where the log […]