Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, aiohttp 3, awesomeversion 4, backoff 5, buildPythonPackage 6, pydantic 7, fetchFromGitHub 8, poetry-core 9, yarl 10, aresponses 11, pytest-asyncio 12, pytestCheckHook 13, pythonOlder 14}: 15 16buildPythonPackage rec { 17 pname = "demetriek"; 18 version = "0.4.0"; 19 format = "pyproject"; 20 21 disabled = pythonOlder "3.9"; 22 23 src = fetchFromGitHub { 24 owner = "frenck"; 25 repo = "python-demetriek"; 26 rev = "refs/tags/v${version}"; 27 hash = "sha256-LCHHBcZgO9gw5jyaJiiS4lKyb0ut+PJvKTylIvIKHhc="; 28 }; 29 30 postPatch = '' 31 # Upstream doesn't set a version for the pyproject.toml 32 substituteInPlace pyproject.toml \ 33 --replace "0.0.0" "${version}" \ 34 --replace "--cov" "" 35 ''; 36 37 nativeBuildInputs = [ 38 poetry-core 39 ]; 40 41 propagatedBuildInputs = [ 42 aiohttp 43 awesomeversion 44 backoff 45 pydantic 46 yarl 47 ]; 48 49 nativeCheckInputs = [ 50 aresponses 51 pytest-asyncio 52 pytestCheckHook 53 ]; 54 55 pythonImportsCheck = [ 56 "demetriek" 57 ]; 58 59 meta = with lib; { 60 description = "Python client for LaMetric TIME devices"; 61 homepage = "https://github.com/frenck/python-demetriek"; 62 license = licenses.mit; 63 maintainers = with maintainers; [ fab ]; 64 }; 65}