django-pdb on PyPI

15 views
Skip to first unread message

Tom Christie

unread,
Aug 2, 2011, 4:07:52 PM8/2/11
to django...@googlegroups.com
I've thrown up the django-pdb package on PyPI - hopefully some of y'all will find it a useful little tool.


Suggestions and contributions are of course very welcome.


Here's the basic README...

Make debugging Django easier
======================

Adding pdb.set_trace() to your source files every time you want to break into pdb sucks.

Don't do that.

Do this.

Installation
========

Install using `pip`, add to your INSTALLED_APPS:
    pip install django-pdb

    INSTALLED_APPS = (
        ...
        'django_pdb',
    )

Usage
=====

manage.py runserver
    Drops into pdb at the start of a view if the URL includes a 'pdb' GET parameter

manage.py runserver --pdb
    Drops into pdb at the start of every view

manage.py test --pdb
    Drops into pdb on test errors/failures

Matt Schinckel

unread,
Aug 2, 2011, 10:06:20 PM8/2/11
to django...@googlegroups.com
That's nice.

I've figured out how to enable this and django-devserver (since they both override 'runserver', they clash).

You can just install the middleware (dependent upon settings.DEBUG, naturally).

Documentation patch forthcoming.

Matt.

Tom Christie

unread,
Aug 3, 2011, 3:36:01 AM8/3/11
to django...@googlegroups.com
Thanks for that! Yeah there's nothing very complicated about it, but makes for a useful little package.
T.
Reply all
Reply to author
Forward
0 new messages