diff options
author | umarcor <unai.martinezcorral@ehu.eus> | 2021-08-23 21:35:40 +0200 |
---|---|---|
committer | umarcor <unai.martinezcorral@ehu.eus> | 2021-08-23 21:35:40 +0200 |
commit | 3dddb7dea5cf898f7f05699a7f6aee8906f9ce24 (patch) | |
tree | 4095a2b7e8f083ca22a9f4ca0424960002d34f9f /pyGHDL/lsp | |
parent | a3255c69df60fee697e1ee546052a8abe86fb4ff (diff) | |
download | ghdl-3dddb7dea5cf898f7f05699a7f6aee8906f9ce24.tar.gz ghdl-3dddb7dea5cf898f7f05699a7f6aee8906f9ce24.tar.bz2 ghdl-3dddb7dea5cf898f7f05699a7f6aee8906f9ce24.zip |
pyGHDL/lsp: style
Diffstat (limited to 'pyGHDL/lsp')
-rw-r--r-- | pyGHDL/lsp/lsp.py | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/pyGHDL/lsp/lsp.py b/pyGHDL/lsp/lsp.py index 04d2c24ce..ec35f0aca 100644 --- a/pyGHDL/lsp/lsp.py +++ b/pyGHDL/lsp/lsp.py @@ -52,9 +52,8 @@ def path_to_uri(path): # On windows, do not quote the colon after the driver letter, as # it is not quoted in uri from the client. path = path.replace("\\", "/") - return "file:///" + path[:2] + quote(path[2:]) - else: - return "file://" + quote(path) + return "file:///{0}{1}".format(path[:2], quote(path[2:])) + return "file://{0}".format(quote(path)) class LanguageProtocolServer(object): @@ -125,9 +124,7 @@ class LanguageProtocolServer(object): log.exception("Caught exception while handling %s with params %s:", method, params) self.show_message( MessageType.Error, - ("Caught exception while handling {}, " + "see VHDL language server output for details.").format( - method - ), + ("Caught exception while handling {}, see VHDL language server output for details.").format(method), ) response = None if tid is None: |