about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/jupyter-contrib-nbextensions/default.nix
blob: 73ba031e39925e969bccc9760b2a7d554150f983 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
{ lib
, buildPythonPackage
, fetchFromGitHub
, ipython_genutils
, jupyter-contrib-core
, jupyter-highlight-selected-word
, jupyter-nbextensions-configurator
, lxml
, nose
, pytestCheckHook
, notebook
}:

buildPythonPackage rec {
  pname = "jupyter-contrib-nbextensions";
  version = "0.7.0";

  src = fetchFromGitHub {
    owner = "ipython-contrib";
    repo = "jupyter_contrib_nbextensions";
    rev = "refs/tags/${version}";
    hash = "sha256-1o8tBfRw6jNcKfNE7xXrQaEhx+KOv7mLOruvuMDtJ1Q=";
  };

  propagatedBuildInputs = [
    ipython_genutils
    jupyter-contrib-core
    jupyter-highlight-selected-word
    jupyter-nbextensions-configurator
    lxml
  ];

  nativeCheckInputs = [
    nose
    pytestCheckHook
  ];

  disabledTestPaths = [
    # Thoses tests fail upstream because of nbconvert being too recent
    # https://github.com/ipython-contrib/jupyter_contrib_nbextensions/issues/1606
    "tests/test_exporters.py"

    # Requires to run jupyter which is not feasible here
    "tests/test_application.py"
  ];

  pythonImportsCheck = [ "jupyter_contrib_nbextensions" ];

  meta = with lib; {
    description = "A collection of various notebook extensions for Jupyter";
    homepage = "https://github.com/ipython-contrib/jupyter_contrib_nbextensions";
    license = licenses.bsd3;
    maintainers = with maintainers; [ GaetanLepage ];
    # https://github.com/ipython-contrib/jupyter_contrib_nbextensions/issues/1647
    broken = versionAtLeast notebook.version "7";
  };
}