1{ lib
2, aiohttp
3, aresponses
4, buildPythonPackage
5, certifi
6, fetchFromGitHub
7, poetry-core
8, pytest-aiohttp
9, pytest-asyncio
10, pytestCheckHook
11, pythonOlder
12, yarl
13}:
14
15buildPythonPackage rec {
16 pname = "pytile";
17 version = "2023.10.0";
18 format = "pyproject";
19
20 disabled = pythonOlder "3.10";
21
22 src = fetchFromGitHub {
23 owner = "bachya";
24 repo = "pytile";
25 rev = "refs/tags/${version}";
26 hash = "sha256-L1Ovpxn7Y+reK8YcVBPwoRjKxcyByrPGz5i/csGzKfE=";
27 };
28
29 nativeBuildInputs = [
30 poetry-core
31 ];
32
33 propagatedBuildInputs = [
34 aiohttp
35 certifi
36 yarl
37 ];
38
39 nativeCheckInputs = [
40 aresponses
41 pytest-aiohttp
42 pytest-asyncio
43 pytestCheckHook
44 ];
45
46 disabledTestPaths = [
47 # Ignore the examples as they are prefixed with test_
48 "examples/"
49 ];
50
51 pythonImportsCheck = [
52 "pytile"
53 ];
54
55 __darwinAllowLocalNetworking = true;
56
57 meta = with lib; {
58 description = " Python API for Tile Bluetooth trackers";
59 longDescription = ''
60 pytile is a simple Python library for retrieving information on Tile
61 Bluetooth trackers (including last location and more).
62 '';
63 homepage = "https://github.com/bachya/pytile";
64 changelog = "https://github.com/bachya/pytile/releases/tag/${version}";
65 license = with licenses; [ mit ];
66 maintainers = with maintainers; [ fab ];
67 };
68}