Created
February 10, 2017 21:47
-
-
Save mpontillo/6fdd6aacd50d1b07867cf99304f50472 to your computer and use it in GitHub Desktop.
Django temporary logging example
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 logging | |
l = logging.getLogger('django.db.backends') | |
l.setLevel(logging.DEBUG) | |
l.addHandler(logging.StreamHandler()) | |
# Code to execute QuerySet goes here. | |
l.setLevel(logging.INFO) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment