1{
2 lib,
3 aioconsole,
4 bleak,
5 buildPythonPackage,
6 dbus-next,
7 fetchFromGitHub,
8 numpy,
9 pytest-asyncio,
10 pytestCheckHook,
11 pythonOlder,
12 setuptools,
13}:
14
15buildPythonPackage rec {
16 pname = "bless";
17 version = "0.2.6";
18 pyproject = true;
19
20 disabled = pythonOlder "3.7";
21
22 src = fetchFromGitHub {
23 owner = "kevincar";
24 repo = "bless";
25 tag = "v${version}";
26 hash = "sha256-dAdA+d75iE6v6t4mfgvwhRsIARLW+IqCGmaMABaDlZg=";
27 };
28
29 postPatch = ''
30 sed -i "/pysetupdi/d" setup.py
31 '';
32
33 nativeBuildInputs = [ setuptools ];
34
35 propagatedBuildInputs = [
36 bleak
37 dbus-next
38 ];
39
40 nativeCheckInputs = [
41 aioconsole
42 numpy
43 pytest-asyncio
44 pytestCheckHook
45 ];
46
47 pythonImportsCheck = [ "bless" ];
48
49 meta = with lib; {
50 broken = true; # not compatible with bleak>=1.0 and no maintenance since 2024-03
51 description = "Library for creating a BLE Generic Attribute Profile (GATT) server";
52 homepage = "https://github.com/kevincar/bless";
53 changelog = "https://github.com/kevincar/bless/releases/tag/v${version}";
54 license = licenses.mit;
55 maintainers = with maintainers; [ fab ];
56 };
57}