Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pythonOlder, 6 7 # build-system 8 poetry-core, 9 10 # propagates 11 aiofiles, 12 blinker, 13 click, 14 flask, 15 hypercorn, 16 importlib-metadata, 17 itsdangerous, 18 jinja2, 19 markupsafe, 20 pydata-sphinx-theme, 21 python-dotenv, 22 typing-extensions, 23 werkzeug, 24 25 # tests 26 hypothesis, 27 mock, 28 py, 29 pytest-asyncio, 30 pytest7CheckHook, 31}: 32 33buildPythonPackage rec { 34 pname = "quart"; 35 version = "0.19.6"; 36 pyproject = true; 37 38 src = fetchFromGitHub { 39 owner = "pallets"; 40 repo = "quart"; 41 rev = "refs/tags/${version}"; 42 hash = "sha256-oR03Qu93F+pcWywbdYgMKIAdohBNezlGz04ws3yGAxs="; 43 }; 44 45 build-system = [ poetry-core ]; 46 47 postPatch = '' 48 substituteInPlace pyproject.toml \ 49 --replace "--no-cov-on-fail " "" 50 ''; 51 52 dependencies = 53 [ 54 aiofiles 55 blinker 56 click 57 flask 58 hypercorn 59 itsdangerous 60 jinja2 61 markupsafe 62 pydata-sphinx-theme 63 python-dotenv 64 werkzeug 65 ] 66 ++ lib.optionals (pythonOlder "3.10") [ 67 importlib-metadata 68 typing-extensions 69 ]; 70 71 pythonImportsCheck = [ "quart" ]; 72 73 nativeCheckInputs = [ 74 hypothesis 75 mock 76 py 77 pytest-asyncio 78 pytest7CheckHook 79 ]; 80 81 meta = with lib; { 82 description = "Async Python micro framework for building web applications"; 83 mainProgram = "quart"; 84 homepage = "https://github.com/pallets/quart/"; 85 changelog = "https://github.com/pallets/quart/blob/${src.rev}/CHANGES.rst"; 86 license = licenses.mit; 87 maintainers = with maintainers; [ hexa ]; 88 }; 89}