summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/python-lsp-server
diff options
context:
space:
mode:
authorFabian Affolter <mail@fabian-affolter.ch>2021-07-03 13:36:10 +0200
committerFabian Affolter <mail@fabian-affolter.ch>2021-07-03 13:36:10 +0200
commitbebb18083ffa6b89946b76ebe3cb07fa929487c1 (patch)
tree8957f652f04c98d4003578c3be443225294b77fa /pkgs/development/python-modules/python-lsp-server
parent14da51500d417ab901402fca0aa3c19e03b77e84 (diff)
python3Packages.python-lsp-server: init at 1.1.0
Diffstat (limited to 'pkgs/development/python-modules/python-lsp-server')
-rw-r--r--pkgs/development/python-modules/python-lsp-server/default.nix81
1 files changed, 81 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/python-lsp-server/default.nix b/pkgs/development/python-modules/python-lsp-server/default.nix
new file mode 100644
index 000000000000..6a2c396ecf89
--- /dev/null
+++ b/pkgs/development/python-modules/python-lsp-server/default.nix
@@ -0,0 +1,81 @@
+{ lib
+, autopep8
+, buildPythonPackage
+, fetchFromGitHub
+, flake8
+, flaky
+, jedi
+, matplotlib
+, mccabe
+, numpy
+, pandas
+, pluggy
+, pycodestyle
+, pydocstyle
+, pyflakes
+, pylint
+, pyqt5
+, pytestCheckHook
+, python-lsp-jsonrpc
+, pythonOlder
+, rope
+, ujson
+, yapf
+}:
+
+buildPythonPackage rec {
+ pname = "python-lsp-server";
+ version = "1.1.0";
+ disabled = pythonOlder "3.6";
+
+ src = fetchFromGitHub {
+ owner = "python-lsp";
+ repo = pname;
+ rev = "v${version}";
+ sha256 = "1akdpfnylqg2mcwpkqmdwcg6j6hab23slp5rfjfidhphig2f2yjv";
+ };
+
+ propagatedBuildInputs = [
+ autopep8
+ flake8
+ jedi
+ mccabe
+ pluggy
+ pycodestyle
+ pydocstyle
+ pyflakes
+ pylint
+ python-lsp-jsonrpc
+ rope
+ ujson
+ yapf
+ ];
+
+ checkInputs = [
+ flaky
+ matplotlib
+ numpy
+ pandas
+ pyqt5
+ pytestCheckHook
+ ];
+
+ postPatch = ''
+ substituteInPlace setup.cfg \
+ --replace "--cov-report html --cov-report term --junitxml=pytest.xml" "" \
+ --replace "--cov pylsp --cov test" ""
+ '';
+
+ preCheck = ''
+ export HOME=$(mktemp -d);
+ '';
+
+ pythonImportsCheck = [ "pylsp" ];
+
+ meta = with lib; {
+ description = "Python implementation of the Language Server Protocol";
+ homepage = "https://github.com/python-lsp/python-lsp-server";
+ license = licenses.mit;
+ maintainers = with maintainers; [ fab ];
+ };
+}