[Zope] Refreshing modules imported into external methods

Dieter Maurer dieter at handshake.de
Sat Dec 20 06:46:53 EST 2003


Michael Hartl wrote at 2003-12-17 10:29 -0800:
>...
>> create a refreshing External Method that uses Python's "reload" to reload
>> modules
>
>This worked.  It seems strange from a Python perspective, since there's no
>need to use "reload" inside ordinary programs; Python automatically
>re-imports any code that has changed.

In fact, Python does not care at all when you change a module
after it has been imported. Especially, it does *not* reload
modules in ordinary programs.

When you see automatic reloading then this is a feature of something
outside Python (e.g. Zope or the IDE).

-- 
Dieter



More information about the Zope mailing list