at master 1.1 kB view raw
1{ 2 lib, 3 aiohttp, 4 aresponses, 5 buildPythonPackage, 6 fetchFromGitHub, 7 poetry-core, 8 pytest-asyncio, 9 pytest-cov-stub, 10 pytestCheckHook, 11 pythonOlder, 12 yarl, 13}: 14 15buildPythonPackage rec { 16 pname = "gridnet"; 17 version = "5.0.1"; 18 pyproject = true; 19 20 disabled = pythonOlder "3.11"; 21 22 src = fetchFromGitHub { 23 owner = "klaasnicolaas"; 24 repo = "python-gridnet"; 25 tag = "v${version}"; 26 hash = "sha256-HVBUAasK7lFsj/tT0j70x/2w4RJtnHWfX/1XbfKKLf8="; 27 }; 28 29 postPatch = '' 30 substituteInPlace pyproject.toml \ 31 --replace "0.0.0" "${version}" 32 ''; 33 34 nativeBuildInputs = [ poetry-core ]; 35 36 propagatedBuildInputs = [ 37 aiohttp 38 yarl 39 ]; 40 41 nativeCheckInputs = [ 42 aresponses 43 pytest-asyncio 44 pytest-cov-stub 45 pytestCheckHook 46 ]; 47 48 pythonImportsCheck = [ "gridnet" ]; 49 50 meta = with lib; { 51 description = "Asynchronous Python client for NET2GRID devices"; 52 homepage = "https://github.com/klaasnicolaas/python-gridnet"; 53 changelog = "https://github.com/klaasnicolaas/python-gridnet/releases/tag/v${version}"; 54 license = licenses.mit; 55 maintainers = with maintainers; [ dotlambda ]; 56 }; 57}