diff options
Diffstat (limited to 'pkgs/development/python-modules/tinytuya/default.nix')
-rw-r--r-- | pkgs/development/python-modules/tinytuya/default.nix | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/tinytuya/default.nix b/pkgs/development/python-modules/tinytuya/default.nix new file mode 100644 index 0000000000000..cb9b37a01a84d --- /dev/null +++ b/pkgs/development/python-modules/tinytuya/default.nix @@ -0,0 +1,47 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + + # build-system + setuptools, + + # dependencies + cryptography, + requests, + colorama, +}: + +buildPythonPackage rec { + pname = "tinytuya"; + version = "1.14.0"; + pyproject = true; + + src = fetchFromGitHub { + owner = "jasonacox"; + repo = "tinytuya"; + rev = "refs/tags/v${version}"; + hash = "sha256-ytM7S0V/hDOCb3RyzAXZEd2zV/sMVQPrah/2zRACMsQ="; + }; + + build-system = [ setuptools ]; + + dependencies = [ + cryptography + requests + colorama + ]; + + # Tests require real network resources + doCheck = false; + + pythonImportsCheck = [ "tinytuya" ]; + + meta = with lib; { + description = "Python API for Tuya WiFi smart devices using a direct local area network (LAN) connection or the cloud (TuyaCloud API)"; + homepage = "https://github.com/jasonacox/tinytuya"; + changelog = "https://github.com/jasonacox/tinytuya/releases/tag/v${version}"; + license = licenses.mit; + maintainers = with maintainers; [ pathob ]; + }; +} |