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