nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 22.05 99 lines 1.8 kB view raw
1{ lib 2, stdenv 3, buildPythonPackage 4, cheroot 5, fetchPypi 6, jaraco_collections 7, more-itertools 8, objgraph 9, path 10, portend 11, pytest-forked 12, pytest-services 13, pytestCheckHook 14, pythonAtLeast 15, pythonOlder 16, requests-toolbelt 17, routes 18, setuptools-scm 19, simplejson 20, zc_lockfile 21}: 22 23buildPythonPackage rec { 24 pname = "cherrypy"; 25 version = "18.6.1"; 26 format = "setuptools"; 27 28 disabled = pythonOlder "3.7"; 29 30 src = fetchPypi { 31 pname = "CherryPy"; 32 inherit version; 33 hash = "sha256-8z6HKG57PjCeBOciXY5JOC2dd3PmCSJB1/YTiTxWNJU="; 34 }; 35 36 nativeBuildInputs = [ 37 setuptools-scm 38 ]; 39 40 propagatedBuildInputs = [ 41 # required 42 cheroot 43 portend 44 more-itertools 45 zc_lockfile 46 jaraco_collections 47 # optional 48 routes 49 simplejson 50 ]; 51 52 checkInputs = [ 53 objgraph 54 path 55 pytest-forked 56 pytest-services 57 pytestCheckHook 58 requests-toolbelt 59 ]; 60 61 preCheck = '' 62 # Disable doctest plugin because times out 63 substituteInPlace pytest.ini \ 64 --replace "--doctest-modules" "-vvv" 65 sed -i "/--cov/d" pytest.ini 66 ''; 67 68 pytestFlagsArray = [ 69 "-W" 70 "ignore::DeprecationWarning" 71 ]; 72 73 disabledTests = [ 74 # Keyboard interrupt ends test suite run 75 "KeyboardInterrupt" 76 # daemonize and autoreload tests have issue with sockets within sandbox 77 "daemonize" 78 "Autoreload" 79 ] ++ lib.optionals stdenv.isDarwin [ 80 "test_block" 81 ]; 82 83 disabledTestPaths = lib.optionals stdenv.isDarwin [ 84 "cherrypy/test/test_config_server.py" 85 ]; 86 87 __darwinAllowLocalNetworking = true; 88 89 pythonImportsCheck = [ 90 "cherrypy" 91 ]; 92 93 meta = with lib; { 94 description = "Object-oriented HTTP framework"; 95 homepage = "https://www.cherrypy.org"; 96 license = licenses.bsd3; 97 maintainers = with maintainers; [ ]; 98 }; 99}