Created
January 7, 2020 09:26
-
-
Save xen/9949cde024db65a374dcd5ff6b685ced to your computer and use it in GitHub Desktop.
This file contains 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
# django shell console logging SQL queries | |
import logging | |
logger = logging.getLogger('django.db.backends') | |
logger.setLevel(logging.DEBUG) | |
logger.addHandler(logging.StreamHandler()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment