1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, fetchpatch
5, pyserial
6, pytestCheckHook
7}:
8
9buildPythonPackage rec {
10 pname = "aqualogic";
11 version = "2.6";
12
13 src = fetchFromGitHub {
14 owner = "swilson";
15 repo = pname;
16 rev = version;
17 sha256 = "sha256-dAC/0OjvrC8J/5pu5vcOKV/WqgkAlz0LuFl0up6FQRM=";
18 };
19
20 patches = [
21 (fetchpatch {
22 name = "allow-iobase-objects.patch";
23 url = "https://github.com/swilson/aqualogic/commit/185fe25a86c82c497a55c78914b55ed39f5ca339.patch";
24 sha256 = "072jrrsqv86bn3skibjc57111jlpm8pq2503997fl3h4v6ziwdxg";
25 })
26 ];
27
28 propagatedBuildInputs = [ pyserial ];
29
30 checkInputs = [ pytestCheckHook ];
31
32 pythonImportsCheck = [ "aqualogic" ];
33
34 meta = with lib; {
35 description = "Python library to interface with Hayward/Goldline AquaLogic/ProLogic pool controllers";
36 homepage = "https://github.com/swilson/aqualogic";
37 license = with licenses; [ mit ];
38 maintainers = with maintainers; [ fab ];
39 };
40}