depot/third_party/nixpkgs/pkgs/development/python-modules/yowsup/default.nix
Default email ae91cbe6cc Project import generated by Copybara.
GitOrigin-RevId: 536fe36e23ab0fc8b7f35c24603422eee9fc17a2
2021-02-05 18:12:51 +01:00

35 lines
931 B
Nix

{ buildPythonPackage, lib, fetchFromGitHub, six, python-axolotl, pytest
, isPy3k, consonance, appdirs
}:
buildPythonPackage rec {
pname = "yowsup";
version = "3.2.3";
# The Python 2.x support of this package is incompatible with `six==1.11`:
# https://github.com/tgalal/yowsup/issues/2416#issuecomment-365113486
disabled = !isPy3k;
src = fetchFromGitHub {
owner = "tgalal";
repo = "yowsup";
rev = "v${version}";
sha256 = "0wb8yl685nr1i3vx89hwan5m6a482x8g48f5ksvdlph538p720pm";
};
checkInputs = [ pytest ];
checkPhase = ''
HOME=$(mktemp -d) py.test yowsup
'';
patches = [ ./dependency-fixes.patch ];
propagatedBuildInputs = [ six python-axolotl consonance appdirs ];
meta = with lib; {
homepage = "https://github.com/tgalal/yowsup";
description = "The python WhatsApp library";
license = licenses.gpl3;
maintainers = with maintainers; [ SuperSandro2000 ];
};
}