File tree 2 files changed +9
-3
lines changed
2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -36,8 +36,14 @@ def pyls_document_symbols(config, document):
36
36
if (not sym_full_name .startswith (module_name ) and
37
37
not sym_full_name .startswith ('__main__' )):
38
38
continue
39
-
40
- if _include_def (d ) and document .path == d .module_path :
39
+ try :
40
+ docismodule = os .path .samefile (document .path , d .module_path )
41
+ except AttributeError :
42
+ # Python 2 on Windows has no .samefile, but then these are
43
+ # strings for sure
44
+ docismodule = document .path == d .module_path
45
+
46
+ if _include_def (d ) and docismodule :
41
47
tuple_range = _tuple_range (d )
42
48
if tuple_range in exclude :
43
49
continue
Original file line number Diff line number Diff line change 10
10
'configparser; python_version<"3.0"' ,
11
11
'future>=0.14.0; python_version<"3"' ,
12
12
'backports.functools_lru_cache; python_version<"3.2"' ,
13
- 'jedi>=0.17.2,<0.18 .0' ,
13
+ 'jedi>=0.17.2,<0.19 .0' ,
14
14
'python-jsonrpc-server>=0.4.0' ,
15
15
'pluggy' ,
16
16
'ujson<=2.0.3 ; platform_system!="Windows" and python_version<"3.0"' ,
You can’t perform that action at this time.
0 commit comments