~/talk

Effortless Logging: A deep dive into the logging module

Talkat PyCon 2018 · on Sunday, 2018-05-13· [python, observability]
slides:none on file

Deep dive into Python’s logging module explains exactly what happens: logger creates a LogRecord with context, handlers emit to streams or files and can send HTTP or email, formatters turn records into strings, and filters accept or reject records. Coverage includes hierarchy and propagate semantics (parent handlers run, filters don’t), levels and exc_info/stack_info, configuration via basicConfig/dict/file (basicConfig only applies once), JSON and buffered handlers, QueueHandler for multiprocessing, and practical recipes that work.

AI-written summary · about

  1. 0:00Intro
  2. 1:16Why logging matters
  3. 2:41Versatility & Configurability
  4. 3:42How logging works
  5. 5:47Formatter
  6. 6:57The hierarchy
  7. 8:38The actual flow
  8. 9:58How to use it
  9. 10:56Common misuses
  10. 13:06How to configure it
  11. 14:05dictConfig
  12. 14:36Demo!
  13. 16:20Logger.handle
  14. 16:38Logger.callHandlers
  15. 17:47Handler.handle
  16. 18:28Sample recipes
  17. 19:16Logging JSON
  18. 19:39Using filters to add context
  19. 20:24Buffering
  20. 20:55Non blocking handling of records
  21. 21:41Console output
  22. 22:10Lazy evaluation
  23. 27:06Questions
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.