[SciPy-user] interactive work with extension modules

Alexandre Fayolle alexandre.fayolle at logilab.fr
Mon Aug 4 11:54:18 EDT 2008


On Mon, Aug 04, 2008 at 05:27:43PM +0200, Alexandre Fayolle wrote:
> On Mon, Aug 04, 2008 at 05:04:56PM +0200, Steve Schmerler wrote:
> > Hi all
> > 
> > I've read in the scipy and IPython archives that Python cannot reload extension
> > modules (C and Fortran). So if I change and re-compile my extension and do
> >     
> >     >>> reload(foo) 
> >     >>> foo.some_function(args)
> > 
> > in the [i]python shell, there is no change to "foo". Even
> > 
> >     >>> del foo
> >     >>> import foo
> >     >>> foo.some_function(args)
> 
> I suspect that some_function is imported indirectly in foo.py (and not
> defined in that module), because I'm able to do the following:

My bad, I hadn't notice the 'extension' in 'extension module'. 

-- 
Alexandre Fayolle                              LOGILAB, Paris (France)
Formations Python, Zope, Plone, Debian:  http://www.logilab.fr/formations
Développement logiciel sur mesure:       http://www.logilab.fr/services
Informatique scientifique:               http://www.logilab.fr/science
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 481 bytes
Desc: Digital signature
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20080804/61d9fade/attachment.sig>


More information about the SciPy-User mailing list