2017-08-31 20:01:15 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi,
|
|
|
|
pytest, requests, requests_oauthlib, six
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asana";
|
2018-02-17 13:18:08 +00:00
|
|
|
version = "0.7.0";
|
2017-08-31 20:01:15 +01:00
|
|
|
name = "${pname}-${version}";
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Python client library for Asana";
|
|
|
|
homepage = https://github.com/asana/python-asana;
|
|
|
|
license = lib.licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-02-17 13:18:08 +00:00
|
|
|
sha256 = "a7ff4a78529257a5412e78cafd6b3025523364c0ab628d579f2771dd66b254bc";
|
2017-08-31 20:01:15 +01:00
|
|
|
};
|
|
|
|
|
2017-10-25 19:04:35 +01:00
|
|
|
checkInputs = [ pytest ];
|
2017-08-31 20:01:15 +01: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
|
|
|
|
'';
|
|
|
|
|
|
|
|
# ERROR: file not found: tests
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
py.test tests
|
|
|
|
'';
|
|
|
|
|
|
|
|
}
|