Skip to content

Commit ca6fc6d

Browse files
authored
Merge pull request #580 from stonebig/patch-1
patch jupyter_lsp-1.1.4 for 'native' Windows users
2 parents 3901053 + deb840b commit ca6fc6d

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,12 @@
1010

1111
- fixed name of jupyterlab-lsp package displayed in JupyterLab UI ([#570], thanks @marimeireles)
1212
- removed vendored CodeMirror from distribution ([#576])
13+
- fix encoding on Windows for non-conda installs ([#580], thanks @stonebig)
1314

1415
[#557]: https://github.com/krassowski/jupyterlab-lsp/pull/557
1516
[#570]: https://github.com/krassowski/jupyterlab-lsp/pull/570
1617
[#576]: https://github.com/krassowski/jupyterlab-lsp/pull/576
18+
[#580]: https://github.com/krassowski/jupyterlab-lsp/pull/580
1719

1820
### `@krassowski/jupyterlab-lsp 3.5.0` (2020-03-22)
1921

python_packages/jupyter_lsp/jupyter_lsp/virtual_documents_shadow.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,15 @@ def read_lines(self):
4141
lines = [""]
4242
try:
4343
# TODO: what to do about bad encoding reads?
44-
lines = self.path.read_text().splitlines()
44+
lines = self.path.read_text(encoding='utf-8').splitlines()
4545
except FileNotFoundError:
4646
pass
4747
return lines
4848

4949
@run_on_executor
5050
def write_lines(self):
5151
self.path.parent.mkdir(parents=True, exist_ok=True)
52-
self.path.write_text("\n".join(self.lines))
52+
self.path.write_text("\n".join(self.lines), encoding='utf-8')
5353

5454
@staticmethod
5555
def trim(lines: list, character: int, side: int):

0 commit comments

Comments
 (0)