Created
April 5, 2024 16:30
-
-
Save FelipeBarrosCruz/ece68f12aff7040f7c0ccbff4b08405d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import structlog | |
structlog.configure( | |
processors=[ | |
structlog.processors.TimeStamper(fmt="iso"), | |
structlog.processors.add_log_level, | |
structlog.processors.EventRenamer("msg"), | |
structlog.processors.JSONRenderer(), | |
] | |
) | |
def create_logger(**kwargs): | |
return structlog.get_logger(**kwargs) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment