2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytestCheckHook,
|
2024-07-31 10:19:44 +00:00
|
|
|
fetchpatch2,
|
|
|
|
setuptools,
|
2023-08-04 22:07:22 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "jsonable";
|
|
|
|
version = "0.3.1";
|
2024-07-31 10:19:44 +00:00
|
|
|
pyproject = true;
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "halfak";
|
|
|
|
repo = "python-jsonable";
|
|
|
|
rev = "refs/tags/${version}";
|
|
|
|
hash = "sha256-3FIzG2djSZOPDdoYeKqs3obQjgHrFtyp0sdBwZakkHA=";
|
|
|
|
};
|
|
|
|
|
2024-07-31 10:19:44 +00:00
|
|
|
patches = [
|
|
|
|
# https://github.com/halfak/python-jsonable/pull/2
|
|
|
|
(fetchpatch2 {
|
|
|
|
name = "eq-to-assert.patch";
|
|
|
|
url = "https://github.com/halfak/python-jsonable/pull/2/commits/335e61bb4926e644aef983f7313793bf506d2463.patch";
|
|
|
|
hash = "sha256-tCVA0wG+UMyB6oaNf4nbZ2BPWkNumaGPcjP5VJKegBo=";
|
|
|
|
})
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
2024-07-31 10:19:44 +00:00
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
pythonImportsCheck = [ "jsonable" ];
|
|
|
|
|
2024-07-31 10:19:44 +00:00
|
|
|
meta = {
|
2023-08-04 22:07:22 +00:00
|
|
|
description = "Provides an abstract base class and utilities for defining trivially JSONable python objects";
|
|
|
|
homepage = "https://github.com/halfak/python-jsonable";
|
2024-07-31 10:19:44 +00:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [ GaetanLepage ];
|
2023-08-04 22:07:22 +00:00
|
|
|
};
|
|
|
|
}
|