I am using Django 1.8 for a project. I have kept the logs in the settings as :
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'formatters': {
'verbose': {
'format': '%(levelname)s %(asctime)s %(module)s \
%(process)d %(lineno)d %(thread)d %(message)s'
},
'simple': {
'format': '%(levelname)s %(lineno)d %(message)s'
},
},
'handlers': {
'null': {
'level': 'DEBUG',
'class': 'logging.NullHandler',
'formatter': 'verbose'
},
'console': {
'level': 'DEBUG',
'class': 'logging.StreamHandler',
'formatter': 'verbose'
},
'console_simple': {
'level': 'DEBUG',
'class': 'logging.StreamHandler',
'formatter': 'simple'
},
'mail_admins': {
'level': 'ERROR',
'class': 'django.utils.log.AdminEmailHandler',
'formatter': 'verbose'
},
'requests': {
'level': 'INFO',
'class': 'logging.FileHandler',
'filename': '/var/log/request.log',
'formatter': 'verbose'
},
},
'loggers': {
'django': {
'handlers': ['null'],
'propagate': True,
'level': 'INFO',
},
'django.request': {
'handlers': ['console'],
'level': 'WARNING',
'propagate': False,
},
'logger': {
'handlers': ['requests'],
'level': 'INFO',
'propagate': False,
},
},
}
I get errors regularly as Bad Request, so I want to see what data is sent through the front-end to the function calls.
I want to know if there is a way so that I can store the data sent by the front-end to the functions?Any advances will be appreciated.