1{ lib
2, buildPythonPackage
3, fetchPypi
4, python
5, nose
6, pytest
7, mock
8, ipython
9, ipykernel
10, traitlets
11, notebook
12, widgetsnbextension
13}:
14
15buildPythonPackage rec {
16 pname = "ipywidgets";
17 version = "7.1.2";
18 name = "${pname}-${version}";
19
20 src = fetchPypi {
21 inherit pname version;
22 sha256 = "4263ce721a1e5b53a84c4595a5e296d270ae0dc534401b536f4dda64e0b0ca02";
23 };
24
25 # Tests are not distributed
26 # doCheck = false;
27
28 buildInputs = [ nose pytest mock ];
29 propagatedBuildInputs = [
30 ipython
31 ipykernel
32 traitlets
33 notebook
34 widgetsnbextension
35 ];
36
37 checkPhase = ''
38 ${python.interpreter} -m unittest discover
39 '';
40
41 meta = {
42 description = "IPython HTML widgets for Jupyter";
43 homepage = http://ipython.org/;
44 license = lib.licenses.bsd3;
45 maintainers = with lib.maintainers; [ fridh ];
46 };
47}