From b74f3813409eeb8ddb3fe1081397d9f69d78001f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 21 Jan 2023 11:15:30 +0100 Subject: [PATCH] python310Packages.lsprotocol: adjust meta - disable on unsupported Python releases --- .../python-modules/lsprotocol/default.nix | 29 +++++++++++-------- 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/pkgs/development/python-modules/lsprotocol/default.nix b/pkgs/development/python-modules/lsprotocol/default.nix index 4cd00f771d8e..3b97c36a1804 100644 --- a/pkgs/development/python-modules/lsprotocol/default.nix +++ b/pkgs/development/python-modules/lsprotocol/default.nix @@ -1,13 +1,14 @@ { lib +, attrs , buildPythonPackage +, cattrs , fetchFromGitHub , flit-core -, cattrs -, attrs -, nox -, pytest -, pyhamcrest , jsonschema +, nox +, pyhamcrest +, pytest +, pythonOlder }: buildPythonPackage rec { @@ -15,10 +16,12 @@ buildPythonPackage rec { version = "2022.0.0a9"; format = "pyproject"; + disabled = pythonOlder "3.7"; + src = fetchFromGitHub { owner = "microsoft"; repo = pname; - rev = version; + rev = "refs/tags/${version}"; hash = "sha256-6XecPKuBhwtkmZrGozzO+VEryI5wwy9hlvWE1oV6ajk="; }; @@ -28,14 +31,14 @@ buildPythonPackage rec { ]; propagatedBuildInputs = [ - cattrs attrs + cattrs ]; checkInputs = [ - pytest - pyhamcrest jsonschema + pyhamcrest + pytest ]; checkPhase = '' @@ -47,12 +50,14 @@ buildPythonPackage rec { runHook postCheck ''; - pythonImportsCheck = [ "lsprotocol" ]; + pythonImportsCheck = [ + "lsprotocol" + ]; meta = with lib; { homepage = "https://github.com/microsoft/lsprotocol"; - description = "Python implementation of the Language Server Protocol."; + description = "Python implementation of the Language Server Protocol"; license = licenses.mit; - maintainers = with maintainers; [ doronbehar ]; + maintainers = with maintainers; [ doronbehar fab ]; }; }