Python Logging: A meditation on silent failures
Not every failure has a stack trace. Tests are better at detecting the wrong outcome than the absence of the right outcome. Sometimes your code is right, but a dependency update causes a breaking change. Silent failures are a regrettable but inevitable part of maintaining a living codebase.
Logging is an important part of sane, sustainable development. We'll cover a few examples where proactive logging can catch silent failures. Then we'll talk about how to set up a basic logger and a customized formatter for your app. Lastly, we'll talk about the balance between logs that are too sparse and logs that are too dense.
This talk will give Python beginners the tools to start listening to their logs without getting lost in the noise.