Skip to content

Commit fe605cf

Browse files
tomasr8loic-simon
andauthored
Attributes come first
Co-authored-by: Loïc Simon <loic.pano@gmail.com>
1 parent f7dc27b commit fe605cf

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

Lib/_pyrepl/_module_completer.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@ def complete(self, from_name: str | None, name: str | None) -> tuple[list[str],
118118
# attributes use their actual value.
119119
submodule_set = set(submodules)
120120
attr_map = dict(zip(attr_names, attr_values))
121-
all_values = [attr_map.get(n) if n not in submodule_set else sys
122-
for n in all_names]
121+
all_values = [attr_map[n] if n in attr_map else sys for n in all_names]
123122
return all_names, all_values, action
124123

125124
def find_modules(self, path: str, prefix: str) -> list[str]:

0 commit comments

Comments
 (0)