depot/third_party/nixpkgs/pkgs/development/python-modules/nexia/default.nix
Default email 3b21d1e521 Project import generated by Copybara.
GitOrigin-RevId: 23cd13167a1432550e48734079c2ffeeb441fb96
2021-07-15 00:03:04 +02:00

43 lines
818 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
, requests
, requests-mock
}:
buildPythonPackage rec {
pname = "nexia";
version = "0.9.9";
disabled = pythonOlder "3.5";
src = fetchFromGitHub {
owner = "bdraco";
repo = pname;
rev = version;
sha256 = "sha256-OamQ6p8o23lVeOB/KyNQI7G8xZaAaVNYacoRfbNKJtk=";
};
propagatedBuildInputs = [
requests
];
checkInputs = [
requests-mock
pytestCheckHook
];
postPatch = ''
substituteInPlace setup.py --replace '"pytest-runner",' ""
'';
pythonImportsCheck = [ "nexia" ];
meta = with lib; {
description = "Python module for Nexia thermostats";
homepage = "https://github.com/bdraco/nexia";
license = with licenses; [ asl20 ];
maintainers = with maintainers; [ fab ];
};
}