listparser: switch from buildPythonPackage -> stdenv.mkDerivation

This commit is contained in:
2024-06-24 20:51:48 +00:00
parent 5d1c52d0bc
commit d9437bf4aa

View File

@@ -1,34 +1,33 @@
{
buildPythonPackage,
fetchFromGitHub,
lib,
lxml,
nix-update-script,
poetry-core,
python3,
pypaBuildHook,
pypaInstallHook,
pytestCheckHook,
requests,
stdenv,
toPythonModule,
}:
buildPythonPackage rec {
toPythonModule (
stdenv.mkDerivation (finalAttrs: {
pname = "listparser";
version = "0.20";
format = "pyproject";
src = fetchFromGitHub {
owner = "kurtmckee";
repo = "listparser";
rev = "v${version}";
rev = "v${finalAttrs.version}";
hash = "sha256-eg9TrjDgvHsYt/0JQ7MK/uGc3KK3uGr3jRxzG0FlySg=";
};
nativeBuildInputs = [
poetry-core
];
nativeCheckInputs = [
pytestCheckHook
pypaBuildHook
pypaInstallHook
];
propagatedBuildInputs = [
@@ -36,6 +35,16 @@ buildPythonPackage rec {
lxml
];
nativeCheckInputs = [
pytestCheckHook
];
pythonImportsCheck = [
"listparser"
];
doCheck = true;
passthru.updateScript = nix-update-script { };
meta = with lib; {
@@ -45,5 +54,5 @@ buildPythonPackage rec {
maintainers = [ maintainers.colinsane ];
platforms = platforms.linux;
};
}
})
)