1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 colorlover,
6 ipython,
7 ipywidgets,
8 numpy,
9 pandas,
10 plotly,
11 pytestCheckHook,
12 setuptools,
13 six,
14}:
15
16buildPythonPackage rec {
17 pname = "cufflinks";
18 version = "0.17.3";
19 pyproject = true;
20
21 src = fetchPypi {
22 inherit pname version;
23 hash = "sha256-SMGzQG3AMABBIZZkie68VRjOpw/U4/FjebSRMoUBpkQ=";
24 };
25
26 # replace duplicated pandas method
27 # https://github.com/santosjorge/cufflinks/pull/249#issuecomment-1759619149
28 postPatch = ''
29 substituteInPlace tests.py \
30 --replace-fail "from nose.tools import assert_equals" "def assert_equals(x, y): assert x == y" \
31 --replace-fail "df.ix" "df.loc"
32 '';
33
34 build-system = [ setuptools ];
35
36 dependencies = [
37 colorlover
38 ipython
39 ipywidgets
40 numpy
41 pandas
42 plotly
43 six
44 ];
45
46 pythonImportsCheck = [ "cufflinks" ];
47
48 nativeCheckInputs = [ pytestCheckHook ];
49
50 pytestFlagsArray = [ "tests.py" ];
51
52 meta = with lib; {
53 description = "Productivity Tools for Plotly + Pandas";
54 homepage = "https://github.com/santosjorge/cufflinks";
55 license = licenses.mit;
56 maintainers = with maintainers; [ ];
57 };
58}