1{ lib 2, buildPythonPackage 3, pythonOlder 4, fetchFromGitHub 5, aiohttp 6, xmltodict 7, python-socketio 8, websocket-client 9}: 10 11buildPythonPackage rec { 12 pname = "pycontrol4"; 13 version = "1.1.0"; 14 15 disabled = pythonOlder "3.6"; 16 17 format = "setuptools"; 18 19 src = fetchFromGitHub { 20 owner = "lawtancool"; 21 repo = "pyControl4"; 22 rev = "v${version}"; 23 hash = "sha256-dMv2b6dbMauPvPf4LHKmLF4jnXYRYe6A+2lDtiZDUhY="; 24 }; 25 26 postPatch = '' 27 substituteInPlace setup.py \ 28 --replace "python-socketio>=4,<5" "python-socketio>=4" 29 ''; 30 31 propagatedBuildInputs = [ 32 aiohttp 33 xmltodict 34 python-socketio 35 websocket-client 36 ]; 37 38 # tests access network 39 doCheck = false; 40 41 pythonImportsCheck = [ 42 "pyControl4.account" 43 "pyControl4.alarm" 44 "pyControl4.director" 45 "pyControl4.light" 46 ]; 47 48 meta = with lib; { 49 description = "Python 3 asyncio package for interacting with Control4 systems"; 50 homepage = "https://github.com/lawtancool/pyControl4"; 51 license = licenses.asl20; 52 maintainers = with maintainers; [ dotlambda ]; 53 }; 54}