mirror of
https://github.com/python/cpython.git
synced 2025-12-31 04:23:37 +00:00
[3.14] gh-137282: Fix TypeError in tab completion and dir() of concurrent.futures (GH-137214) (#137284)
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
This commit is contained in:
parent
f17d77f112
commit
9e8a9ac11a
3 changed files with 4 additions and 1 deletions
|
|
@ -44,7 +44,7 @@
|
|||
|
||||
|
||||
def __dir__():
|
||||
return __all__ + ('__author__', '__doc__')
|
||||
return __all__ + ['__author__', '__doc__']
|
||||
|
||||
|
||||
def __getattr__(name):
|
||||
|
|
|
|||
|
|
@ -72,6 +72,8 @@ def check_all(self, modname):
|
|||
all_set = set(all_list)
|
||||
self.assertCountEqual(all_set, all_list, "in module {}".format(modname))
|
||||
self.assertEqual(keys, all_set, "in module {}".format(modname))
|
||||
# Verify __dir__ is non-empty and doesn't produce an error
|
||||
self.assertTrue(dir(sys.modules[modname]))
|
||||
|
||||
def walk_modules(self, basedir, modpath):
|
||||
for fn in sorted(os.listdir(basedir)):
|
||||
|
|
|
|||
|
|
@ -0,0 +1 @@
|
|||
Fix tab completion and :func:`dir` on :mod:`concurrent.futures`.
|
||||
Loading…
Add table
Add a link
Reference in a new issue