1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 numpy,
6 pdm-backend,
7 pytestCheckHook,
8 pythonAtLeast,
9 pythonOlder,
10 setuptools,
11}:
12
13buildPythonPackage rec {
14 pname = "jsonconversion";
15 version = "1.1.1";
16 pyproject = true;
17
18 disabled = pythonOlder "3.11";
19
20 src = fetchFromGitHub {
21 owner = "DLR-RM";
22 repo = "python-jsonconversion";
23 tag = version;
24 hash = "sha256-FGgvSDweZM1xrdrDLFiGmdAtgxoFjglUlMV+fgo7/ls=";
25 };
26
27 build-system = [ pdm-backend ];
28
29 pythonRemoveDeps = [
30 "pytest-runner"
31 "pytest"
32 ];
33
34 pythonRelaxDeps = [ "numpy" ];
35
36 dependencies = [
37 numpy
38 setuptools
39 ];
40
41 nativeCheckInputs = [ pytestCheckHook ];
42
43 pythonImportsCheck = [ "jsonconversion" ];
44
45 disabledTests = lib.optionals (pythonAtLeast "3.13") [ "test_dict" ];
46
47 meta = with lib; {
48 description = "This python module helps converting arbitrary Python objects into JSON strings and back";
49 homepage = "https://github.com/DLR-RM/python-jsonconversion";
50 changelog = "https://github.com/DLR-RM/python-jsonconversion/releases/tag/${version}";
51 license = licenses.bsd2;
52 maintainers = with maintainers; [ terlar ];
53 };
54}