Alexandre Vassalotti added the comment:

Thank you, Paul, for the patches.

I reviewed the patches and improved them. Here the list of changes:
   - Added unit test for the import fixers.
   - Renamed Lib/Queue.py to Lib/queue.py.
   - Updated Tools/webchecker/wsgui.py.
   - Updated the documentation.

Hopefully, the patches won't get out of date by the time we do the
library reorganization.

----------
assignee:  -> brett.cannon
keywords: +py3k
nosy: +alexandre.vassalotti, brett.cannon
versions: +Python 3.0 -Python 2.6
Added file: http://bugs.python.org/file8865/queue-import-fixer.patch

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1005>
__________________________________
Index: tests/test_fixers.py
===================================================================
--- tests/test_fixers.py	(revision 59312)
+++ tests/test_fixers.py	(working copy)
@@ -1273,6 +1273,7 @@
                "cStringIO": ("io", ["StringIO"]),
                "__builtin__" : ("builtins", ["open", "Exception",
                    "__debug__", "str"]),
+               "Queue": ("queue", ["Empty", "Full", "Queue"]),
               }
 
     def test_import_module(self):
Index: fixes/fix_imports.py
===================================================================
--- fixes/fix_imports.py	(revision 59312)
+++ fixes/fix_imports.py	(working copy)
@@ -4,6 +4,7 @@
   * StringIO -> io
   * cStringIO -> io
   * md5 -> hashlib
+  * Queue -> queue
 """
 # Author: Collin Winter
 
@@ -16,7 +17,8 @@
 
 MAPPING = {"StringIO":  ("io", ["StringIO"]),
            "cStringIO": ("io", ["StringIO"]),
-           "__builtin__" : ("builtins", builtin_names), 
+           "__builtin__": ("builtins", builtin_names),
+           "Queue": ("queue", ["Empty", "Full", "Queue"]),
           }
 
 
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to