From 45e67eb30e88dabd2b36253a28e6b5c0b4f5ec79 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 10 Apr 2024 10:41:18 +0200 Subject: [PATCH] python312Packages.ajsonrpc: refactor --- .../python-modules/ajsonrpc/default.nix | 23 ++++++++++++++----- 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/ajsonrpc/default.nix b/pkgs/development/python-modules/ajsonrpc/default.nix index 47643f6e94b4..41f074aacc0e 100644 --- a/pkgs/development/python-modules/ajsonrpc/default.nix +++ b/pkgs/development/python-modules/ajsonrpc/default.nix @@ -1,26 +1,37 @@ -{ lib, pythonOlder, buildPythonPackage, fetchPypi, pytestCheckHook }: +{ lib +, pythonOlder +, buildPythonPackage +, fetchPypi +, pytestCheckHook +, setuptools +}: buildPythonPackage rec { pname = "ajsonrpc"; version = "1.2.0"; - format = "setuptools"; + pyproject = true; - disabled = pythonOlder "3.5"; + disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - sha256 = "791bac18f0bf0dee109194644f151cf8b7ff529c4b8d6239ac48104a3251a19f"; + hash = "sha256-eRusGPC/De4QkZRkTxUc+Lf/UpxLjWI5rEgQSjJRoZ8="; }; + build-system = [ + setuptools + ]; + nativeCheckInputs = [ pytestCheckHook ]; pythonImportsCheck = [ "ajsonrpc" ]; meta = with lib; { - description = "Async JSON-RPC 2.0 protocol + asyncio server"; - mainProgram = "async-json-rpc-server"; + description = "Async JSON-RPC 2.0 protocol and asyncio server"; homepage = "https://github.com/pavlov99/ajsonrpc"; + changelog = "https://github.com/pavlov99/ajsonrpc/releases/tag/${version}"; license = licenses.mit; maintainers = with maintainers; [ oxzi ]; + mainProgram = "async-json-rpc-server"; }; }