1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 python-dateutil,
6 pytestCheckHook,
7 pythonOlder,
8 setuptools,
9}:
10
11buildPythonPackage rec {
12 pname = "python-crontab";
13 version = "3.3.0";
14 pyproject = true;
15
16 disabled = pythonOlder "3.7";
17
18 src = fetchPypi {
19 pname = "python_crontab";
20 inherit version;
21 hash = "sha256-AHyK7mjd3z4E7E3OD6wSS5O9aL50cPyV0qlhehXeKRs=";
22 };
23
24 build-system = [ setuptools ];
25
26 dependencies = [ python-dateutil ];
27
28 nativeCheckInputs = [ pytestCheckHook ];
29
30 disabledTests = [
31 "test_07_non_posix_shell"
32 # doctest that assumes /tmp is writeable, awkward to patch
33 "test_03_usage"
34 # Test is assuming $CURRENT_YEAR is not a leap year
35 "test_19_frequency_at_month"
36 "test_20_frequency_at_year"
37 ];
38
39 pythonImportsCheck = [ "crontab" ];
40
41 meta = with lib; {
42 description = "Python API for crontab";
43 longDescription = ''
44 Crontab module for reading and writing crontab files
45 and accessing the system cron automatically and simply using a direct API.
46 '';
47 homepage = "https://gitlab.com/doctormo/python-crontab/";
48 license = licenses.lgpl3Plus;
49 maintainers = with maintainers; [ kfollesdal ];
50 };
51}