at master 1.5 kB view raw
1{ 2 lib, 3 aiohttp, 4 aresponses, 5 buildPythonPackage, 6 fetchFromGitHub, 7 fetchpatch, 8 poetry-core, 9 pytest-asyncio, 10 pytest-cov-stub, 11 pytestCheckHook, 12 pythonOlder, 13 yarl, 14}: 15 16buildPythonPackage rec { 17 pname = "cemm"; 18 version = "0.5.1"; 19 pyproject = true; 20 21 disabled = pythonOlder "3.9"; 22 23 src = fetchFromGitHub { 24 owner = "klaasnicolaas"; 25 repo = "python-cemm"; 26 tag = "v${version}"; 27 hash = "sha256-BorgGHxoEeIGyJKqe9mFRDpcGHhi6/8IV7ubEI8yQE4="; 28 }; 29 30 patches = [ 31 # https://github.com/klaasnicolaas/python-cemm/pull/360 32 (fetchpatch { 33 name = "remove-setuptools-dependency.patch"; 34 url = "https://github.com/klaasnicolaas/python-cemm/commit/1e373dac078f18563264e6733baf6a93962cac4b.patch"; 35 hash = "sha256-DVNn4BZwi8yNpKFmzt7YSYhzzB4vaAyrd/My8TtYzj0="; 36 }) 37 ]; 38 39 postPatch = '' 40 substituteInPlace pyproject.toml \ 41 --replace-fail '"0.0.0"' '"${version}"' 42 ''; 43 44 build-system = [ poetry-core ]; 45 46 dependencies = [ 47 aiohttp 48 yarl 49 ]; 50 51 __darwinAllowLocalNetworking = true; 52 53 nativeCheckInputs = [ 54 aresponses 55 pytest-asyncio 56 pytest-cov-stub 57 pytestCheckHook 58 ]; 59 60 pythonImportsCheck = [ "cemm" ]; 61 62 meta = with lib; { 63 description = "Module for interacting with CEMM devices"; 64 homepage = "https://github.com/klaasnicolaas/python-cemm"; 65 changelog = "https://github.com/klaasnicolaas/python-cemm/releases/tag/v${version}"; 66 license = with licenses; [ mit ]; 67 maintainers = with maintainers; [ fab ]; 68 }; 69}