Python Django not showing stack trace

1.7k views Asked by At

I installed a fresh copy of Python 3.4 and Django 1.8.2 on my Windows 7 machine.

In my settings.py file DEBUG is set to True.

My admin page is working. I am using the built-in web server.

The problem is when I try to open an existing page in the project I get "Error 500" and no stack trace so I can fix the issue.

Opening non-existent pages also ends up with no stack trace and only "Error 404".

1

There are 1 answers

3
itzMEonTV On

In settings.py. Add these(for development)

DEBUG = True
TEMPLATE_DEBUG = True
LOGGING = {
    'version': 1,
    'disable_existing_loggers': False,
    'handlers': {
        'file': {
            'level': 'DEBUG',
            'class': 'logging.StreamHandler',
        },
    },
    'loggers': {
        'django.request': {
            'handlers': ['file'],
            'level': 'DEBUG',
            'propagate': True,
        },
    },
}