diff --git a/pkgs/development/python-modules/tesla-wall-connector/default.nix b/pkgs/development/python-modules/tesla-wall-connector/default.nix new file mode 100644 index 000000000000..8aaaa2cb0fad --- /dev/null +++ b/pkgs/development/python-modules/tesla-wall-connector/default.nix @@ -0,0 +1,47 @@ +{ lib +, aiohttp +, backoff +, aioresponses +, buildPythonPackage +, fetchPypi +, pytest-aiohttp +, pytestCheckHook +, poetry-core +, pythonOlder +}: + +buildPythonPackage rec { + pname = "tesla-wall-connector"; + version = "1.0.0"; + format = "pyproject"; + + disabled = pythonOlder "3.8"; + + src = fetchPypi { + inherit pname version; + sha256 = "PVgM6tC8jy/tXytkAVC0Y4Oatap5YFA3vpkUgAdyTxM="; + }; + + nativeBuildInputs = [ + poetry-core + ]; + + propagatedBuildInputs = [ + aiohttp + backoff + ]; + + # https://github.com/einarhauks/tesla-wall-connector/issues/1 + doCheck = false; + + pythonImportsCheck = [ + "tesla_wall_connector" + ]; + + meta = with lib; { + description = "Python library for communicating with a Tesla Wall Connector"; + homepage = "https://github.com/einarhauks/tesla-wall-connector"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2211b67732d4..39c1cf723621 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -9305,6 +9305,8 @@ in { tern = callPackage ../development/python-modules/tern { }; + tesla-wall-connector = callPackage ../development/python-modules/tesla-wall-connector { }; + teslajsonpy = callPackage ../development/python-modules/teslajsonpy { }; tess = callPackage ../development/python-modules/tess { };