[Python-checkins] r62585 - peps/trunk/pep-3108.txt

brett.cannon python-checkins at python.org
Tue Apr 29 23:46:33 CEST 2008


Author: brett.cannon
Date: Tue Apr 29 23:46:32 2008
New Revision: 62585

Log:
Add more detail about how to handle modules that are renamed.


Modified:
   peps/trunk/pep-3108.txt

Modified: peps/trunk/pep-3108.txt
==============================================================================
--- peps/trunk/pep-3108.txt	(original)
+++ peps/trunk/pep-3108.txt	Tue Apr 29 23:46:32 2008
@@ -895,7 +895,12 @@
 case-insensitive filesystems where only the case of a module's name
 changed.
 
-The stub modules will import the module code based on the new names.
+The stub modules will import the module code based on the new names::
+
+  from sys import modules
+  import new_name
+  modules[__name__] = new_name
+
 As with modules to be removed in 3.0 but not in 2.x,
 ``DeprecationWarning`` will be raised using the ``warnings.warn3k()``
 function.


More information about the Python-checkins mailing list