Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 beautifulsoup4, 4 buildPythonPackage, 5 envoy-utils, 6 fetchFromGitHub, 7 httpx, 8 pyjwt, 9 pytest-asyncio, 10 pytestCheckHook, 11 pytest-raises, 12 pythonOlder, 13 respx, 14}: 15 16buildPythonPackage rec { 17 pname = "envoy-reader"; 18 version = "0.21.3"; 19 format = "setuptools"; 20 21 disabled = pythonOlder "3.7"; 22 23 src = fetchFromGitHub { 24 owner = "jesserizzo"; 25 repo = "envoy_reader"; 26 rev = version; 27 hash = "sha256-aIpZ4ln4L57HwK8H0FqsyNnXosnAp3ingrJI6/MPS90="; 28 }; 29 30 propagatedBuildInputs = [ 31 beautifulsoup4 32 envoy-utils 33 httpx 34 pyjwt 35 ]; 36 37 nativeCheckInputs = [ 38 pytest-raises 39 pytest-asyncio 40 pytestCheckHook 41 respx 42 ]; 43 44 postPatch = '' 45 substituteInPlace setup.py \ 46 --replace "pytest-runner>=5.2" "" \ 47 --replace "pyjwt==2.1.0" "pyjwt>=2.1.0" 48 ''; 49 50 pythonImportsCheck = [ "envoy_reader" ]; 51 52 meta = with lib; { 53 description = "Python module to read from Enphase Envoy units"; 54 homepage = "https://github.com/jesserizzo/envoy_reader"; 55 license = licenses.mit; 56 maintainers = with maintainers; [ fab ]; 57 }; 58}