nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 22.05 58 lines 1.1 kB view raw
1{ lib 2, aiohttp 3, aresponses 4, buildPythonPackage 5, fetchFromGitHub 6, poetry-core 7, pytest-asyncio 8, pytestCheckHook 9, pythonOlder 10, yarl 11}: 12 13buildPythonPackage rec { 14 pname = "p1monitor"; 15 version = "1.1.0"; 16 format = "pyproject"; 17 18 disabled = pythonOlder "3.9"; 19 20 src = fetchFromGitHub { 21 owner = "klaasnicolaas"; 22 repo = "python-p1monitor"; 23 rev = "v${version}"; 24 hash = "sha256-X8by8qVcLEs5xrb4LjNeGomlmERAYYplo3Yqgh9lKrI="; 25 }; 26 27 nativeBuildInputs = [ 28 poetry-core 29 ]; 30 31 propagatedBuildInputs = [ 32 aiohttp 33 yarl 34 ]; 35 36 checkInputs = [ 37 aresponses 38 pytest-asyncio 39 pytestCheckHook 40 ]; 41 42 postPatch = '' 43 substituteInPlace pyproject.toml \ 44 --replace '"0.0.0"' '"${version}"' \ 45 --replace 'addopts = "--cov"' "" 46 ''; 47 48 pythonImportsCheck = [ 49 "p1monitor" 50 ]; 51 52 meta = with lib; { 53 description = "Module for interacting with the P1 Monitor"; 54 homepage = "https://github.com/klaasnicolaas/python-p1monitor"; 55 license = with licenses; [ mit ]; 56 maintainers = with maintainers; [ fab ]; 57 }; 58}