imatge

If you, like me, use the fantastic shell_plus from django-extensions to debug your Django apps, you may want to know how to automatically launch a post-mortem debugger when an uncaught exception happens in your shell.

TIL how to do it:

python manage.py shell_plus -- --pdb