Skip to content

Commit 49f9691

Browse files
committed
Merge branch 'py-lsp-server' of ssh://github.com/maresb/jupyterlab-lsp into maresb-py-lsp-server
2 parents 8565b00 + 16720f5 commit 49f9691

File tree

4 files changed

+56
-4
lines changed

4 files changed

+56
-4
lines changed

python_packages/jupyter_lsp/jupyter_lsp/specs/__init__.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
from .javascript_typescript_langserver import JavascriptTypescriptLanguageServer
88
from .jedi_language_server import JediLanguageServer
99
from .julia_language_server import JuliaLanguageServer
10-
from .pyls import PythonLanguageServer
10+
from .pyls import PalantirPythonLanguageServer
11+
from .python_lsp_server import PythonLSPServer
1112
from .r_languageserver import RLanguageServer
1213
from .sql_language_server import SQLLanguageServer
1314
from .texlab import Texlab
@@ -25,7 +26,8 @@
2526
json = VSCodeJSONLanguageServer()
2627
julia = JuliaLanguageServer()
2728
md = UnifiedLanguageServer()
28-
py = PythonLanguageServer()
29+
py_palantir = PalantirPythonLanguageServer()
30+
py_lsp_server = PythonLSPServer()
2931
r = RLanguageServer()
3032
tex = Texlab()
3133
ts = JavascriptTypescriptLanguageServer()

python_packages/jupyter_lsp/jupyter_lsp/specs/pyls.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from .utils import PythonModuleSpec
33

44

5-
class PythonLanguageServer(PythonModuleSpec):
5+
class PalantirPythonLanguageServer(PythonModuleSpec):
66
python_module = key = "pyls"
77
languages = ["python"]
88
spec = dict(
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
from .config import load_config_schema
2+
from .utils import PythonModuleSpec
3+
4+
5+
class PythonLSPServer(PythonModuleSpec):
6+
python_module = key = "python-lsp-server"
7+
languages = ["python"]
8+
spec = dict(
9+
display_name="python-lsp-server",
10+
mime_types=["text/python", "text/x-ipython"],
11+
urls=dict(
12+
home="https://github.com/python-lsp/python-lsp-server",
13+
issues="https://github.com/python-lsp/python-lsp-server/issues",
14+
),
15+
install=dict(
16+
pip="pip install 'python-lsp-server[all]'",
17+
conda="conda install -c conda-forge python-lsp-server",
18+
),
19+
extend=[
20+
dict(
21+
display_name="pyls-mypy",
22+
install=dict(
23+
pip="pip install pyls-mypy", conda="conda install pyls-mypy"
24+
),
25+
),
26+
dict(
27+
display_name="pyls-black",
28+
install=dict(
29+
pip="pip install pyls-black", conda="conda install pyls-black"
30+
),
31+
),
32+
dict(
33+
display_name="pyls-isort",
34+
install=dict(
35+
pip="pip install pyls-isort",
36+
conda="conda install pyls-isort",
37+
),
38+
),
39+
dict(
40+
display_name="pyls-memestra",
41+
install=dict(
42+
pip="pip install pyls-memestra",
43+
conda="conda install pyls-memestra",
44+
),
45+
),
46+
],
47+
config_schema=load_config_schema(key),
48+
env=dict(PYTHONUNBUFFERED="1"),
49+
)

python_packages/jupyter_lsp/setup.cfg

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ jupyter_lsp_spec_v1 =
3939
javascript-typescript-langserver = jupyter_lsp.specs:ts
4040
jedi-language-server = jupyter_lsp.specs:jedi
4141
julia-language-server = jupyter_lsp.specs:julia
42-
python-language-server = jupyter_lsp.specs:py
42+
python-language-server = jupyter_lsp.specs:py_palantir
43+
python-lsp-server = jupyter_lsp.specs:py_lsp_server
4344
r-languageserver = jupyter_lsp.specs:r
4445
texlab = jupyter_lsp.specs:tex
4546
sql-language-server = jupyter_lsp.specs:sql

0 commit comments

Comments
 (0)