using python debugger (pdb) inside emacs debugger mode ...

Philip Lijnzaad lijnzaad at ebi.ac.uk
Tue Sep 14 11:37:09 EDT 1999


Does anyone have experience with using M-x pdb inside emacs? This part of
gud-mode should be able to grok the python debugger, but I can't get it to
work, and there is little documentation (gud-mode mentions gdb, sdb, dbx,
perldb, xdb, but not pdb).


M-x pdb gives:

  run pdb (like this): pdb 

which doesn't work, as pdb is not defined. Running it like 

  python /usr/local/lib/python1.5/pdb.py ~/python/test.py args 

does not work either, since it chdir()'s to /usr/local/lib/python1.5/ and
also strangely doesn't expand the ~ to "/my/home/dir". If I hand-expand it,
it will only synchronize with the source if I give a few 's' commands, but
then it gets stuck when stepping into a module that it can't find because
os.getcwd() is wrong.

Aaarggh! what am I doing wrong? Any comments appreciated!

This is in emacs 20.3, but emacs 20.4 has the same gud.el 

(BTW, I'm amazed that gud.el, which comprises 2500 lines of fairly
non-trivial stuff, does not include any version information, not as a
variable, nor as comment...)

                                                                      Philip
-- 
The cause of the millenium bug is Homo Sapiens having 10 fingers
-----------------------------------------------------------------------------
Philip Lijnzaad, lijnzaad at ebi.ac.uk | European Bioinformatics Institute,rm A2-24
+44 (0)1223 49 4639                 | Wellcome Trust Genome Campus, Hinxton
+44 (0)1223 49 4468 (fax)           | Cambridgeshire CB10 1SD,  GREAT BRITAIN
PGP fingerprint: E1 03 BF 80 94 61 B6 FC  50 3D 1F 64 40 75 FB 53




More information about the Python-list mailing list