python312Packages.transaction: modernize, add nickcao to maintainers

This commit is contained in:
Nick Cao
2024-12-04 09:29:06 -05:00
parent c50c65c982
commit 360cf296dc
@@ -1,36 +1,51 @@
{
lib,
fetchPypi,
fetchFromGitHub,
buildPythonPackage,
setuptools,
zope-interface,
mock,
pytestCheckHook,
pythonOlder,
}:
buildPythonPackage rec {
pname = "transaction";
version = "5.0";
format = "setuptools";
pyproject = true;
disabled = pythonOlder "3.7";
disabled = pythonOlder "3.8";
src = fetchPypi {
inherit pname version;
hash = "sha256-EG5714K8wMtRGfySJbDJpx38U625OL6QUiOtrvIrEXQ=";
src = fetchFromGitHub {
owner = "zopefoundation";
repo = "transaction";
rev = "refs/tags/${version}";
hash = "sha256-8yvA2dvB69+EqsAa+hc93rgg6D64lcajl6JgFabhjwY=";
};
propagatedBuildInputs = [
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail "setuptools<74" "setuptools"
'';
build-system = [
setuptools
];
dependencies = [
zope-interface
mock
];
nativeCheckInputs = [
pytestCheckHook
];
pythonImportsCheck = [ "transaction" ];
meta = with lib; {
meta = {
description = "Transaction management";
homepage = "https://transaction.readthedocs.io/";
changelog = "https://github.com/zopefoundation/transaction/blob/${version}/CHANGES.rst";
license = licenses.zpl20;
maintainers = [ ];
license = lib.licenses.zpl21;
maintainers = with lib.maintainers; [ nickcao ];
};
}