1{ buildPythonPackage, lib, fetchFromGitHub, six, python-axolotl, pytest 2, isPy3k, consonance, appdirs 3}: 4 5buildPythonPackage rec { 6 pname = "yowsup"; 7 version = "3.2.3"; 8 9 # The Python 2.x support of this package is incompatible with `six==1.11`: 10 # https://github.com/tgalal/yowsup/issues/2416#issuecomment-365113486 11 disabled = !isPy3k; 12 13 src = fetchFromGitHub { 14 owner = "tgalal"; 15 repo = "yowsup"; 16 rev = "v${version}"; 17 sha256 = "0wb8yl685nr1i3vx89hwan5m6a482x8g48f5ksvdlph538p720pm"; 18 }; 19 20 checkInputs = [ pytest ]; 21 checkPhase = '' 22 HOME=$(mktemp -d) py.test yowsup 23 ''; 24 25 patches = [ ./dependency-fixes.patch ]; 26 27 propagatedBuildInputs = [ six python-axolotl consonance appdirs ]; 28 29 meta = with lib; { 30 homepage = "https://github.com/tgalal/yowsup"; 31 description = "The python WhatsApp library"; 32 license = licenses.gpl3; 33 maintainers = with maintainers; [ SuperSandro2000 ]; 34 }; 35}