2018-02-26 23:22:09 +00:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi, pytz, requests, pytest }:
|
2017-11-23 22:53:28 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "astral";
|
2018-11-09 08:10:00 +00:00
|
|
|
version = "1.7.1";
|
2017-11-23 22:53:28 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-11-09 08:10:00 +00:00
|
|
|
sha256 = "01raz1c29v08f05l395v1hxllad35m5ld1jj51knb53c0396y248";
|
2017-11-23 22:53:28 +00:00
|
|
|
};
|
|
|
|
|
2018-02-26 23:22:09 +00:00
|
|
|
propagatedBuildInputs = [ pytz requests ];
|
2017-11-23 22:53:28 +00:00
|
|
|
|
|
|
|
checkInputs = [ pytest ];
|
|
|
|
checkPhase = ''
|
2018-02-26 23:22:09 +00:00
|
|
|
# https://github.com/sffjunkie/astral/pull/13
|
|
|
|
touch src/test/.api_key
|
|
|
|
py.test -m "not webtest"
|
2017-11-23 22:53:28 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Calculations for the position of the sun and the moon";
|
|
|
|
homepage = https://github.com/sffjunkie/astral/;
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ flokli ];
|
|
|
|
};
|
|
|
|
}
|