Emacs and pdb after upgrading to Ubuntu Feisty

Alexander Schmolck a.schmolck at gmail.com
Tue May 8 14:16:19 EDT 2007


levander <levander404 at gmail.com> writes:

> Okay, thanks Alexander and Bernstein.  I'll lookinto Emacs 23, but I'm
> worried about compatibility with modes.  Does all the stuff that works
> in Emacs 21 work in 23?  

I've switched from 21 to 23 a few weeks ago and don't recall any particular
issues (and I'm a fairly hardcore emacs user with pretty complex configuration
and many third-party packages -- my emacs config has 182 matches for
require\|autoload).

> Like even that ipython.el file, does it work in Emacs 23? 

I think as the author I would have noticed by now if it didn't :)

> And, I probably will report a bug to either Ubuntu's Launchpad or to
> Debian's package maintainer for pdb mode (which apparently has been
> integrated into just the gud mode stuff, at least that's how it looks from
> looking around on my system). Does Debian have a web site for reporting bugs
> like Ubuntu does? Or, do I just email the package maintainer?
>
> I'm messing around with ipython.el and ipython now.  It looks like if
> you just want to step through some code that isn't throwing any
> execption, you have to modify the source code of your script to tell
> ipython to stop on this line and start debugging here? 

Nope. Try  ``run -d myscript`` (and ``?run`` for more info). 

I must admit that this doesn't work properly for me though -- I don't get
stepping through the corresponding source in emacs. ``M-x pdb`` works with pdb
as debugger but not with pydb; maybe the problem is missing pydb support in
the relevant regexps?

I can't devote any time to this at the moment, but I'd be pretty interested in
having this working -- so I'd appreciate a note if someone figures out what's
going on (and if a change to ipython.el is needed I'll make sure it gets in).

> With all the raving about ipython, I'm sure it's a great product. But, this
> thing about having to modify your source code really sounds like it sucks.
> I'd be surprised if it were difficult to implement a command line option for
> ipython that tells it to open this file and then start debugging it from the
> top. 

It's already there -- I'm using 0.7.4 svn (which is the ubuntu feisty
package), so I think it should also work for you.

> And, have the emacs mode operate much like it does with pdb, where emacs
> remembers your command line when you invoked pdb, so you just hit "M-x pdb
> RET RET RET ..." to open up your file. But, maybe I just haven't foud it
> yet?

I'd type something like ``run -<Meta>+<P>`` (with M-p bound
to `comint-previous-matching-input-from-input') or M-r, which is even fewer
keystrokes.

'as




More information about the Python-list mailing list