[Python-checkins] r62932 - python/trunk/Doc/tutorial/modules.rst

georg.brandl python-checkins at python.org
Fri May 9 08:39:58 CEST 2008


Author: georg.brandl
Date: Fri May  9 08:39:58 2008
New Revision: 62932

Log:
Add a note about using reload().


Modified:
   python/trunk/Doc/tutorial/modules.rst

Modified: python/trunk/Doc/tutorial/modules.rst
==============================================================================
--- python/trunk/Doc/tutorial/modules.rst	(original)
+++ python/trunk/Doc/tutorial/modules.rst	Fri May  9 08:39:58 2008
@@ -103,6 +103,13 @@
 
 This imports all names except those beginning with an underscore (``_``).
 
+.. note::
+
+   For efficiency reasons, each module is only imported once per interpreter
+   session.  Therefore, if you change your modules, you must restart the
+   interpreter -- or, if it's just one module you want to test interactively,
+   use :func:`reload`, e.g. ``reload('modulename')``.
+
 
 .. _tut-modulesasscripts:
 


More information about the Python-checkins mailing list