1{
2 lib,
3 buildPythonPackage,
4 django,
5 fetchFromGitHub,
6 hatch-fancy-pypi-readme,
7 hatchling,
8 hatch-vcs,
9 python,
10 pythonOlder,
11}:
12
13buildPythonPackage rec {
14 pname = "django-simple-history";
15 version = "3.10.1";
16 pyproject = true;
17
18 disabled = pythonOlder "3.9";
19
20 src = fetchFromGitHub {
21 owner = "jazzband";
22 repo = "django-simple-history";
23 tag = version;
24 hash = "sha256-th0ZkHMKWcI6nNhgjpkvmyKaJ/TdWK12mBPUTFab8g4=";
25 };
26
27 build-system = [
28 hatch-fancy-pypi-readme
29 hatchling
30 hatch-vcs
31 ];
32
33 dependencies = [ django ];
34
35 checkPhase = ''
36 runHook preCheck
37 ${python.interpreter} runtests.py
38 runHook postCheck
39 '';
40
41 pythonImportsCheck = [ "simple_history" ];
42
43 meta = with lib; {
44 description = "Module to store Django model state on every create/update/delete";
45 homepage = "https://github.com/jazzband/django-simple-history/";
46 changelog = "https://github.com/jazzband/django-simple-history/releases/tag/${src.tag}";
47 license = licenses.bsd3;
48 maintainers = with maintainers; [ derdennisop ];
49 };
50}