1{ 2 lib, 3 aiohttp, 4 amqtt, 5 buildPythonPackage, 6 certifi, 7 docopt, 8 fetchFromGitHub, 9 fetchpatch, 10 geopy, 11 mock, 12 pytest-asyncio_0, 13 pytestCheckHook, 14 pythonOlder, 15}: 16 17buildPythonPackage rec { 18 pname = "volvooncall"; 19 version = "0.10.4"; 20 format = "setuptools"; 21 22 disabled = pythonOlder "3.10"; 23 24 src = fetchFromGitHub { 25 owner = "molobrakos"; 26 repo = "volvooncall"; 27 tag = "v${version}"; 28 hash = "sha256-xr3g93rt3jvxVZrZY7cFh5eBP3k0arsejsgvx8p5EV4="; 29 }; 30 31 patches = [ 32 # Remove asynctest, https://github.com/molobrakos/volvooncall/pull/92 33 (fetchpatch { 34 name = "remove-asnyc.patch"; 35 url = "https://github.com/molobrakos/volvooncall/commit/ef0df403250288c00ed4c600e9dfa79dcba8941e.patch"; 36 hash = "sha256-U+hM7vzD9JSEUumvjPSLpVQcc8jAuZHG3/1dQ3wnIcA="; 37 }) 38 ]; 39 40 propagatedBuildInputs = [ aiohttp ]; 41 42 optional-dependencies = { 43 console = [ 44 certifi 45 docopt 46 geopy 47 ]; 48 mqtt = [ 49 amqtt 50 certifi 51 ]; 52 }; 53 54 checkInputs = [ 55 mock 56 pytest-asyncio_0 57 pytestCheckHook 58 ] 59 ++ optional-dependencies.mqtt; 60 61 pythonImportsCheck = [ "volvooncall" ]; 62 63 meta = with lib; { 64 description = "Retrieve information from the Volvo On Call web service"; 65 homepage = "https://github.com/molobrakos/volvooncall"; 66 changelog = "https://github.com/molobrakos/volvooncall/releases/tag/v${version}"; 67 license = licenses.unlicense; 68 mainProgram = "voc"; 69 maintainers = with maintainers; [ dotlambda ]; 70 }; 71}