From the course: Advanced Django Project: Build High-Traffic Websites with Django

Unlock the full course today

Join today to access over 24,400 courses taught by industry experts.

Logging

Logging

- [Instructor] In this section, I'm going to assume some familiarity with the Python logging package and also logging systems in general. Different log levels, what they mean, why we want to use them, et cetera. Django's logging system extends Python's logging package. You know that thing you get when you type import logging. So in general, if you have any issues with logging in your Django project, you can read the logging docs here in order to solve them. But in this video, we're going to look at what makes logging in Django unique and some of the features they've added on top of it. So one cool thing you can do is configure logging directly in your settings.py file. So I've added a stub dictionary here, but you can define whatever dictionary configuration you want, it's right in settings. This dictionary is the exact same thing that you might pass into a logging.config.dictconfig in any other Python…

Contents