1{ lib 2, aiohttp 3, aresponses 4, buildPythonPackage 5, fetchFromGitHub 6, fetchpatch 7, poetry-core 8, pydantic 9, pytest-aiohttp 10, pytest-asyncio 11, pytest-cov 12, pytestCheckHook 13, pythonOlder 14}: 15 16buildPythonPackage rec { 17 pname = "aionotion"; 18 version = "2023.05.5"; 19 format = "pyproject"; 20 21 disabled = pythonOlder "3.7"; 22 23 src = fetchFromGitHub { 24 owner = "bachya"; 25 repo = pname; 26 rev = version; 27 hash = "sha256-/2sF8m5R8YXkP89bi5zR3h13r5LrFOl1OsixAcX0D4o="; 28 }; 29 30 patches = [ 31 # This patch removes references to setuptools and wheel that are no longer 32 # necessary and changes poetry to poetry-core, so that we don't need to add 33 # unnecessary nativeBuildInputs. 34 # 35 # https://github.com/bachya/aionotion/pull/269 36 # 37 (fetchpatch { 38 name = "clean-up-build-dependencies.patch"; 39 url = "https://github.com/bachya/aionotion/commit/53c7285110d12810f9b43284295f71d052a81b83.patch"; 40 hash = "sha256-RLRbHmaR2A8MNc96WHx0L8ccyygoBUaOulAuRJkFuUM="; 41 }) 42 ]; 43 44 nativeBuildInputs = [ 45 poetry-core 46 ]; 47 48 propagatedBuildInputs = [ 49 aiohttp 50 pydantic 51 ]; 52 53 __darwinAllowLocalNetworking = true; 54 55 nativeCheckInputs = [ 56 aresponses 57 pytest-aiohttp 58 pytest-asyncio 59 pytest-cov 60 pytestCheckHook 61 ]; 62 63 disabledTestPaths = [ 64 "examples" 65 ]; 66 67 pythonImportsCheck = [ 68 "aionotion" 69 ]; 70 71 meta = with lib; { 72 description = "Python library for Notion Home Monitoring"; 73 homepage = "https://github.com/bachya/aionotion"; 74 license = with licenses; [ mit ]; 75 maintainers = with maintainers; [ fab ]; 76 }; 77}