nixpkgs/pkgs/development/python-modules/asana/default.nix

35 lines
845 B
Nix
Raw Normal View History

{ buildPythonPackage, pytest, requests, requests_oauthlib, six
, fetchFromGitHub, responses, stdenv
2017-08-31 21:01:15 +02:00
}:
buildPythonPackage rec {
pname = "asana";
2018-02-17 14:18:08 +01:00
version = "0.7.0";
2017-08-31 21:01:15 +02:00
src = fetchFromGitHub {
owner = "asana";
repo = "python-asana";
rev = "v${version}";
sha256 = "0786y3wxqxxhsb0kkpx4bfzif3dhvv3dmm6vnq58iyj94862kpxf";
2017-08-31 21:01:15 +02:00
};
checkInputs = [ pytest responses ];
2017-08-31 21:01:15 +02:00
propagatedBuildInputs = [ requests requests_oauthlib six ];
patchPhase = ''
echo > requirements.txt
sed -i "s/requests~=2.9.1/requests >=2.9.1/" setup.py
sed -i "s/requests_oauthlib~=0.6.1/requests_oauthlib >=0.6.1/" setup.py
'';
checkPhase = ''
py.test tests
'';
meta = with stdenv.lib; {
description = "Python client library for Asana";
homepage = https://github.com/asana/python-asana;
license = licenses.mit;
};
2017-08-31 21:01:15 +02:00
}