From 359bb3d70abc70865f6e14ed0388dbb1c339c56f Mon Sep 17 00:00:00 2001 From: Nicholas Gates Date: Tue, 21 Jan 2020 20:26:27 +0000 Subject: [PATCH 1/2] Compare paths not URIs --- pyls/plugins/highlight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyls/plugins/highlight.py b/pyls/plugins/highlight.py index adc06b01..5638db81 100644 --- a/pyls/plugins/highlight.py +++ b/pyls/plugins/highlight.py @@ -13,7 +13,7 @@ def is_valid(definition): return definition.line is not None and definition.column is not None def local_to_document(definition): - return not definition.module_path or uris.uri_with(document.uri, path=definition.module_path) == document.uri + return not definition.module_path or definition.module_path == document.path return [{ 'range': { From 7db42f97baef455aba8bb66193750081005f09c5 Mon Sep 17 00:00:00 2001 From: Nicholas Gates Date: Tue, 21 Jan 2020 20:29:52 +0000 Subject: [PATCH 2/2] Remove unused highlight --- pyls/plugins/highlight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyls/plugins/highlight.py b/pyls/plugins/highlight.py index 5638db81..839ffb26 100644 --- a/pyls/plugins/highlight.py +++ b/pyls/plugins/highlight.py @@ -1,6 +1,6 @@ # Copyright 2017 Palantir Technologies, Inc. import logging -from pyls import hookimpl, lsp, uris +from pyls import hookimpl, lsp log = logging.getLogger(__name__)