Skip to content

Commit 70c8e1a

Browse files
committed
Follow imports when going to definitions
This fixes microsoft#1033 following the change of behaviour in jedi's `goto_assignments` in the upgrade from 0.9.0 to 0.11.1. The change is assumed to be a bug-fix since it now appears to obey the `follow_imports` boolean for cases which it previously would follow imports even when the value was set to `False`. Since we actually do want to follow imports here, we set the value to `True` to restore the old behaviour.
1 parent 962c850 commit 70c8e1a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pythonFiles/completion.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -570,7 +570,7 @@ def _process_request(self, request):
570570
if lookup == 'definitions':
571571
defs = []
572572
try:
573-
defs = self._get_definitionsx(script.goto_assignments(follow_imports=False), request['id'])
573+
defs = self._get_definitionsx(script.goto_assignments(follow_imports=True), request['id'])
574574
except:
575575
pass
576576
try:

0 commit comments

Comments
 (0)