2018-07-15 14:38:42 +01:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi, fetchpatch
|
|
|
|
, pytest, jinja2, sphinx, vega_datasets, ipython, glibcLocales
|
2018-12-02 13:04:24 +00:00
|
|
|
, entrypoints, jsonschema, numpy, pandas, six, toolz, typing
|
|
|
|
, pythonOlder, recommonmark }:
|
2017-07-15 06:58:25 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "altair";
|
2019-05-30 07:49:48 +01:00
|
|
|
version = "3.0.1";
|
2017-07-15 06:58:25 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-05-30 07:49:48 +01:00
|
|
|
sha256 = "63934563a7a7b7186335858206a0b9be6043163b8b54a26cd3b3299a9e5e391f";
|
2017-07-15 06:58:25 +01:00
|
|
|
};
|
|
|
|
|
2019-02-17 11:51:12 +00:00
|
|
|
postPatch = ''
|
|
|
|
# Tests require network
|
|
|
|
rm altair/examples/boxplot_max_min.py altair/examples/line_percent.py
|
|
|
|
'';
|
|
|
|
|
2018-12-02 13:04:24 +00:00
|
|
|
checkInputs = [ pytest jinja2 sphinx vega_datasets ipython glibcLocales recommonmark ];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ entrypoints jsonschema numpy pandas six toolz ]
|
|
|
|
++ stdenv.lib.optionals (pythonOlder "3.5") [ typing ];
|
2018-03-20 15:33:08 +00:00
|
|
|
|
2017-07-15 06:58:25 +01:00
|
|
|
checkPhase = ''
|
|
|
|
export LANG=en_US.UTF-8
|
|
|
|
py.test altair --doctest-modules
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A declarative statistical visualization library for Python.";
|
|
|
|
homepage = https://github.com/altair-viz/altair;
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ teh ];
|
2019-02-17 13:00:33 +00:00
|
|
|
platforms = platforms.unix;
|
2017-07-15 06:58:25 +01:00
|
|
|
};
|
|
|
|
}
|