]> granicus.if.org Git - python/commitdiff
Issue #13933: IDLE auto-complete did not work with some imported
authorNed Deily <nad@acm.org>
Sat, 4 Feb 2012 17:36:43 +0000 (18:36 +0100)
committerNed Deily <nad@acm.org>
Sat, 4 Feb 2012 17:36:43 +0000 (18:36 +0100)
module, like hashlib.  (Patch by Roger Serwy)

Lib/idlelib/AutoComplete.py
Misc/NEWS

index fa1733f9a6e97acd44b4c2e8085b57a3cb4c4d5e..519099033f95b0326fd8b3e68f33798b12e03e8a 100644 (file)
@@ -190,7 +190,7 @@ class AutoComplete:
                     bigl = eval("dir()", namespace)
                     bigl.sort()
                     if "__all__" in bigl:
-                        smalll = eval("__all__", namespace)
+                        smalll = list(eval("__all__", namespace))
                         smalll.sort()
                     else:
                         smalll = [s for s in bigl if s[:1] != '_']
@@ -200,7 +200,7 @@ class AutoComplete:
                         bigl = dir(entity)
                         bigl.sort()
                         if "__all__" in bigl:
-                            smalll = entity.__all__
+                            smalll = list(entity.__all__)
                             smalll.sort()
                         else:
                             smalll = [s for s in bigl if s[:1] != '_']
index 136748e6cb729264875e7bc2b8103d00c88ca710..d3a3b9e18d02dc92b1a2fec5281f4029c5ea107a 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -113,6 +113,9 @@ Core and Builtins
 Library
 -------
 
+- Issue #13933: IDLE auto-complete did not work with some imported
+  module, like hashlib.  (Patch by Roger Serwy)
+
 - Issue #13901: Prevent test_distutils failures on OS X with --enable-shared.
 
 - Issue #13676: Handle strings with embedded zeros correctly in sqlite3.