Advertisement
horozov86

SQL Logging Configuration

Nov 9th, 2023
352
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.49 KB | None | 0 0
  1. # Добавя се в края на settings.py
  2.  
  3. LOGGING = {
  4.     'version': 1,
  5.     'disable_existing_loggers': False,
  6.     'handlers': {
  7.         'console': {
  8.             'class': 'logging.StreamHandler'}
  9.        
  10.     },
  11.     'root': {
  12.         'handlers': ['console'],
  13.         'level': 'DEBUG',
  14.     },
  15.     'loggers': {
  16.         'django.db.backends': {
  17.             'handlers': ['console'],
  18.             'level': 'DEBUG',
  19.             'propagate': False,
  20.         }
  21.        
  22.     }
  23.    
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement