Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pytestCheckHook, 6 pythonOlder, 7 setuptools, 8 setuptools-scm, 9 ujson, 10}: 11 12buildPythonPackage rec { 13 pname = "python-lsp-jsonrpc"; 14 version = "1.1.2"; 15 format = "pyproject"; 16 17 disabled = pythonOlder "3.7"; 18 19 src = fetchFromGitHub { 20 owner = "python-lsp"; 21 repo = pname; 22 rev = "refs/tags/v${version}"; 23 hash = "sha256-5WN/31e6WCgXVzevMuQbNjyo/2jjWDF+m48nrLKS+64="; 24 }; 25 26 postPatch = '' 27 substituteInPlace pyproject.toml \ 28 --replace "--cov-report html --cov-report term --junitxml=pytest.xml --cov pylsp_jsonrpc --cov test" "" 29 ''; 30 31 nativeBuildInputs = [ 32 setuptools 33 setuptools-scm 34 ]; 35 36 propagatedBuildInputs = [ ujson ]; 37 38 nativeCheckInputs = [ pytestCheckHook ]; 39 40 pythonImportsCheck = [ "pylsp_jsonrpc" ]; 41 42 meta = with lib; { 43 description = "Python server implementation of the JSON RPC 2.0 protocol"; 44 homepage = "https://github.com/python-lsp/python-lsp-jsonrpc"; 45 changelog = "https://github.com/python-lsp/python-lsp-jsonrpc/blob/v${version}/CHANGELOG.md"; 46 license = licenses.mit; 47 maintainers = with maintainers; [ fab ]; 48 }; 49}