mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-05 00:41:00 +01:00
fix module import to return list instead of generator
This commit is contained in:
parent
5caa9b7a76
commit
e7d85a8234
1 changed files with 2 additions and 2 deletions
|
@ -212,9 +212,9 @@ class Completer(object):
|
|||
mod = importlib.import_module(ltoks[1])
|
||||
except ImportError:
|
||||
return set(), lprefix
|
||||
out = (i[0]
|
||||
out = [i[0]
|
||||
for i in inspect.getmembers(mod)
|
||||
if i[0].startswith(prefix))
|
||||
if i[0].startswith(prefix)]
|
||||
return out, lprefix
|
||||
if len(ltoks) == 2 and ltoks[0] == 'from':
|
||||
comps = ('{} '.format(i) for i in self.module_complete(prefix))
|
||||
|
|
Loading…
Add table
Reference in a new issue