[IPython-user] python vs. ipython

Fernando Perez Fernando.Perez at colorado.edu
Tue Oct 25 14:12:01 CDT 2005

Fernando Perez wrote:

> Well, what I do in that case is put
> import foo
> reload(foo)  # remove when done testing
> statements for the modules I'm modifying.  It's a bit of a hack, but a small 
> and simple enough one that I don't mind it.

I forgot to add that this doesn't work for extension code, since the python 
interpreter simply can't reload extension modules (to my knowledge).

You may also want to look into ipyhon's dreload routine, which does 'deep' 
(recursive) reloading of modules.  It's not perfect, but often does the trick 
with nested imports you need to update.



More information about the IPython-user mailing list