2024-05-20 09:35:49 +02:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
flit-core,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
tinycss2,
|
2020-07-01 12:31:53 -04:00
|
|
|
}:
|
2018-04-07 13:31:54 +02:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "cssselect2";
|
2022-12-30 20:13:03 +01:00
|
|
|
version = "0.7.0";
|
2024-05-20 09:35:14 +02:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2018-04-07 13:31:54 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2023-03-03 01:48:06 +01:00
|
|
|
hash = "sha256-HM2YTauJ/GiVUEOspOGwPgzynK2YgPbijjunp0sUqlo=";
|
2018-04-07 13:31:54 +02:00
|
|
|
};
|
|
|
|
|
2021-12-03 22:14:34 -08:00
|
|
|
postPatch = ''
|
|
|
|
sed -i '/^addopts/d' pyproject.toml
|
|
|
|
'';
|
|
|
|
|
2024-05-20 09:35:49 +02:00
|
|
|
build-system = [ flit-core ];
|
2022-03-09 16:56:53 +01:00
|
|
|
|
2024-05-20 09:35:49 +02:00
|
|
|
dependencies = [ tinycss2 ];
|
2018-04-07 13:31:54 +02:00
|
|
|
|
2024-05-20 09:35:49 +02:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2021-12-03 22:14:34 -08:00
|
|
|
|
2024-05-20 09:35:49 +02:00
|
|
|
pythonImportsCheck = [ "cssselect2" ];
|
2018-04-07 13:31:54 +02:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "CSS selectors for Python ElementTree";
|
2020-03-31 21:11:51 -04:00
|
|
|
homepage = "https://github.com/Kozea/cssselect2";
|
2024-05-20 09:35:14 +02:00
|
|
|
changelog = "https://github.com/Kozea/cssselect2/releases/tag/${version}";
|
2018-04-07 13:31:54 +02:00
|
|
|
license = licenses.bsd3;
|
2024-05-20 09:35:14 +02:00
|
|
|
maintainers = with maintainers; [ ];
|
2018-04-07 13:31:54 +02:00
|
|
|
};
|
|
|
|
}
|