nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 84 lines 1.7 kB view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 colorlog, 6 fetchFromGitHub, 7 jinja2, 8 mock, 9 pdm-backend, 10 pylibmc, 11 pystache, 12 pytest-cov-stub, 13 pytestCheckHook, 14 pyyaml, 15 redis, 16 requests, 17 tabulate, 18 watchdog, 19}: 20 21buildPythonPackage rec { 22 pname = "cement"; 23 version = "3.0.14"; 24 pyproject = true; 25 26 src = fetchFromGitHub { 27 owner = "datafolklabs"; 28 repo = "cement"; 29 tag = version; 30 hash = "sha256-hZ9kKQmMomjy5nnHKQ2RWB+6vIID8XMn3qutg0wCBq8="; 31 }; 32 33 build-system = [ pdm-backend ]; 34 35 optional-dependencies = { 36 colorlog = [ colorlog ]; 37 jinja2 = [ jinja2 ]; 38 mustache = [ pystache ]; 39 generate = [ pyyaml ]; 40 redis = [ redis ]; 41 memcached = [ pylibmc ]; 42 tabulate = [ tabulate ]; 43 watchdog = [ watchdog ]; 44 yaml = [ pyyaml ]; 45 cli = [ 46 jinja2 47 pyyaml 48 ]; 49 }; 50 51 nativeCheckInputs = [ 52 mock 53 pytest-cov-stub 54 pytestCheckHook 55 requests 56 ] 57 ++ lib.concatAttrValues optional-dependencies; 58 59 pythonImportsCheck = [ "cement" ]; 60 61 # Tests are failing on Darwin 62 doCheck = !stdenv.hostPlatform.isDarwin; 63 64 disabledTests = [ 65 # Test only works with the source from PyPI 66 "test_get_version" 67 ]; 68 69 disabledTestPaths = [ 70 # Tests require network access 71 "tests/ext/test_ext_memcached.py" 72 "tests/ext/test_ext_redis.py" 73 "tests/ext/test_ext_smtp.py" 74 ]; 75 76 meta = { 77 description = "CLI Application Framework for Python"; 78 homepage = "https://builtoncement.com/"; 79 changelog = "https://github.com/datafolklabs/cement/blob/${version}/CHANGELOG.md"; 80 license = lib.licenses.bsd3; 81 maintainers = with lib.maintainers; [ eqyiel ]; 82 mainProgram = "cement"; 83 }; 84}