Enabling warnings¶

To view deprecations, you may need to enable warnings within python. This can be achieved with either the -W flag, or with PYTHONWARNINGS environment variable. For example, you could run your test suite like so:

$ python -W once manage.py test

The above would print all warnings once when they first occur. This is useful to know what violations exist in your code (or occasionally in third party code). However, it only prints the last line of the stack trace. You can use the following to raise the full exception instead: