summaryrefslogtreecommitdiffstats
path: root/pkgs/development/python-modules/pytile/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/pytile/default.nix')
-rw-r--r--pkgs/development/python-modules/pytile/default.nix56
1 files changed, 56 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/pytile/default.nix b/pkgs/development/python-modules/pytile/default.nix
new file mode 100644
index 000000000000..d2fd99f6d166
--- /dev/null
+++ b/pkgs/development/python-modules/pytile/default.nix
@@ -0,0 +1,56 @@
+{ lib
+, aiohttp
+, async-timeout
+, aresponses
+, buildPythonPackage
+, fetchFromGitHub
+, poetry
+, pylint
+, pytest-aiohttp
+, pytest-asyncio
+, pytestCheckHook
+, pythonAtLeast
+}:
+buildPythonPackage rec {
+ pname = "pytile";
+ version = "5.1.0";
+ disabled = pythonAtLeast "3.9";
+
+ src = fetchFromGitHub {
+ owner = "bachya";
+ repo = pname;
+ rev = version;
+ sha256 = "0hdyb8ca4ihqf7yfkr3hbpkwz7g182ycra151y5dxn0319fillc3";
+ };
+
+ format = "pyproject";
+
+ nativeBuildInputs = [ poetry ];
+
+ propagatedBuildInputs = [
+ aiohttp
+ pylint
+ ];
+
+ checkInputs = [
+ aresponses
+ pytest-aiohttp
+ pytest-asyncio
+ pytestCheckHook
+ ];
+
+ # Ignore the examples as they are prefixed with test_
+ pytestFlagsArray = [ "--ignore examples/" ];
+ pythonImportsCheck = [ "pytile" ];
+
+ meta = with lib; {
+ description = " Python API for Tile Bluetooth trackers";
+ longDescription = ''
+ pytile is a simple Python library for retrieving information on Tile
+ Bluetooth trackers (including last location and more).
+ '';
+ homepage = "https://github.com/bachya/pytile";
+ license = with licenses; [ mit ];
+ maintainers = with maintainers; [ fab ];
+ };
+}