2021-02-24 18:30:23 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, ply
|
|
|
|
, pytestCheckHook
|
2023-10-09 19:29:22 +00:00
|
|
|
, pythonOlder
|
|
|
|
, setuptools
|
2021-02-24 18:30:23 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "jsonpath-ng";
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "1.6.0";
|
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2021-02-24 18:30:23 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "h2non";
|
|
|
|
repo = pname;
|
2023-10-09 19:29:22 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-q4kIH/2+VKdlSa+IhJ3ymHpc5gmml9lW4aJS477/YSo=";
|
2021-02-24 18:30:23 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
ply
|
2023-10-09 19:29:22 +00:00
|
|
|
setuptools
|
2021-02-24 18:30:23 +00:00
|
|
|
];
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
nativeCheckInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2021-02-24 18:30:23 +00:00
|
|
|
|
2021-04-12 18:23:04 +00:00
|
|
|
disabledTestPaths = [
|
2021-02-24 18:30:23 +00:00
|
|
|
# Exclude tests that require oslotest
|
|
|
|
"tests/test_jsonpath_rw_ext.py"
|
|
|
|
];
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"jsonpath_ng"
|
|
|
|
];
|
2021-02-24 18:30:23 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
2023-10-09 19:29:22 +00:00
|
|
|
description = "JSONPath implementation";
|
2021-02-24 18:30:23 +00:00
|
|
|
homepage = "https://github.com/h2non/jsonpath-ng";
|
2023-10-09 19:29:22 +00:00
|
|
|
changelog = "https://github.com/h2non/jsonpath-ng/blob/v${version}/History.md";
|
2021-02-24 18:30:23 +00:00
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|