-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Debugging Django
Don Jayamanne edited this page Oct 11, 2016
·
1 revision
Debugging django applications requires the use of the 'Django' debug configuration.
Unfortunately currently live reloading (automatic reloading) of django applications is not possible whilst debugging.
Use either the 'django' debugging configuration or add the following settings in the launch.json
file as following:
{
"name": "Django",
"type": "python",
"request": "launch",
"stopOnEntry": false,
"pythonPath": "${config.python.pythonPath}",
"program": "${workspaceRoot}/manage.py",
"args": [
"runserver",
"--noreload"
],
"debugOptions": [
"WaitOnAbnormalExit",
"WaitOnNormalExit",
"RedirectOutput",
"DjangoDebugging"
]
},
Debugging Django templates is as simple as adding breakpoints to the templates
.
Django templates must be html files.