1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 python,
6 pythonOlder,
7 setuptools,
8
9 # passthru tests
10 apache-beam,
11 datasets,
12}:
13
14buildPythonPackage rec {
15 pname = "dill";
16 version = "0.4.0";
17 format = "pyproject";
18
19 disabled = pythonOlder "3.7";
20
21 src = fetchFromGitHub {
22 owner = "uqfoundation";
23 repo = "dill";
24 tag = version;
25 hash = "sha256-RIyWTeIkK5cS4Fh3TK48XLa/EU9Iwlvcml0CTs5+Uh8=";
26 };
27
28 nativeBuildInputs = [ setuptools ];
29
30 checkPhase = ''
31 runHook preCheck
32 ${python.interpreter} dill/tests/__main__.py
33 runHook postCheck
34 '';
35
36 passthru.tests = {
37 inherit apache-beam datasets;
38 };
39
40 pythonImportsCheck = [ "dill" ];
41
42 meta = with lib; {
43 description = "Serialize all of python (almost)";
44 homepage = "https://github.com/uqfoundation/dill/";
45 changelog = "https://github.com/uqfoundation/dill/releases/tag/dill-${version}";
46 license = licenses.bsd3;
47 maintainers = with maintainers; [ tjni ];
48 };
49}