1
0
forked from VimPlug/jedi

Merge branch 'master' of github.com:davidhalter/jedi

This commit is contained in:
Dave Halter
2020-07-23 01:33:06 +02:00
8 changed files with 31 additions and 13 deletions
+1 -1
View File
@@ -111,7 +111,7 @@ class HelperValueMixin(object):
.py__getattribute__('__anext__').execute_with_values()
.py__getattribute__('__await__').execute_with_values()
.py__stop_iteration_returns()
) # noqa
) # noqa: E124
])
return self.py__iter__(contextualized_node)
+4 -2
View File
@@ -53,8 +53,10 @@ def _infer_annotation_string(context, string, index=None):
value_set = context.infer_node(node)
if index is not None:
value_set = value_set.filter(
lambda value: value.array_type == 'tuple' # noqa
and len(list(value.py__iter__())) >= index
lambda value: (
value.array_type == 'tuple'
and len(list(value.py__iter__())) >= index
)
).py__simple_getitem__(index)
return value_set
+5 -2
View File
@@ -69,8 +69,11 @@ Adds an opening bracket after a function for completions.
# ----------------
if platform.system().lower() == 'windows':
_cache_directory = os.path.join(os.getenv('LOCALAPPDATA') or
os.path.expanduser('~'), 'Jedi', 'Jedi')
_cache_directory = os.path.join(
os.getenv('LOCALAPPDATA') or os.path.expanduser('~'),
'Jedi',
'Jedi',
)
elif platform.system().lower() == 'darwin':
_cache_directory = os.path.join('~', 'Library', 'Caches', 'Jedi')
else: