File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
python_packages/jupyter_lsp/jupyter_lsp Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 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
Original file line number Diff line number Diff 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 ):
You can’t perform that action at this time.
0 commit comments