[Tutor] re-import

johnf jfabiani at yolo.com
Mon Oct 30 03:37:41 CET 2006


On Sunday 29 October 2006 18:25, jhl wrote:
> Hi-
>
> How is the 1st import of a module removed so that new edits on the module
> can be re-imported?
>
> DETAIL:
>
> I am working on a module/file and importing it into a python shell, trying
> it out and then tweaking/editing the module.  Then to see the effects of
> the edits, I want to re-import the file and find that the original import
> persists-- can't get the new/edited module without exiting and restarting
> the python shell.  I've used dir() and del'd every reference to the module
> (and its contents/defs), but the 1st import seems to remain as the source
> for future imports.
>
> Thanks in advance for any & all help,
> -J
 reload(module)
John


More information about the Tutor mailing list