Merge pull request #244492 from GaetanLepage/jupyter-extensions

Jupyter extensions: make sure to run tests (as much as possible)
This commit is contained in:
OTABI Tomoya
2023-08-20 17:53:12 +09:00
committed by GitHub
6 changed files with 64 additions and 17 deletions
@@ -3,6 +3,7 @@
, fetchFromGitHub
, jupyter-core
, notebook
, pytestCheckHook
}:
buildPythonPackage rec {
@@ -21,6 +22,13 @@ buildPythonPackage rec {
notebook
];
nativeCheckInputs = [ pytestCheckHook ];
disabledTestPaths = [
# This test fails upstream too
"tests/test_application.py"
];
pythonImportsCheck = [ "jupyter_contrib_core" ];
meta = with lib; {
@@ -6,6 +6,9 @@
, jupyter-highlight-selected-word
, jupyter-nbextensions-configurator
, lxml
, nose
, pytestCheckHook
, notebook
}:
buildPythonPackage rec {
@@ -27,6 +30,20 @@ buildPythonPackage rec {
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; {
@@ -34,5 +51,7 @@ buildPythonPackage rec {
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";
};
}
@@ -14,6 +14,9 @@ buildPythonPackage rec {
hash = "sha256-KgM//SIfES46uZySwNR4ZOcolnJORltvThsmEvxXoIs=";
};
# This package does not have tests
doChecks = false;
pythonImportsCheck = [ "jupyter_highlight_selected_word" ];
meta = with lib; {
@@ -8,6 +8,9 @@
, notebook
, pyyaml
, tornado
, nose
, pytestCheckHook
, selenium
}:
buildPythonPackage rec {
@@ -39,6 +42,19 @@ buildPythonPackage rec {
tornado
];
nativeCheckInputs = [
nose
pytestCheckHook
selenium
];
# Those tests fails upstream
disabledTestPaths = [
"tests/test_application.py"
"tests/test_jupyterhub.py"
"tests/test_nbextensions_configurator.py"
];
pythonImportsCheck = [ "jupyter_nbextensions_configurator" ];
meta = with lib; {
@@ -1,28 +1,28 @@
{ beautifulsoup4
, bleach
, buildPythonPackage
, defusedxml
, fetchPypi
, fetchpatch
{ lib
, fetchurl
, buildPythonPackage
, pythonOlder
, fetchPypi
, hatchling
, importlib-metadata
, ipywidgets
, beautifulsoup4
, bleach
, defusedxml
, jinja2
, jupyter-core
, jupyterlab-pygments
, lib
, markupsafe
, mistune
, nbclient
, packaging
, pandocfilters
, pygments
, pyppeteer
, pytestCheckHook
, pythonOlder
, tinycss2
, traitlets
, importlib-metadata
, flaky
, ipywidgets
, pyppeteer
, pytestCheckHook
}:
let
@@ -33,15 +33,15 @@ let
};
in buildPythonPackage rec {
pname = "nbconvert";
version = "7.2.5";
version = "7.7.3";
disabled = pythonOlder "3.7";
disabled = pythonOlder "3.8";
format = "pyproject";
src = fetchPypi {
inherit pname version;
hash = "sha256-j9xE/X2UJNt/3G4eg0oC9rhiD/tlN2c4i+L56xb4QYQ=";
hash = "sha256-SlmWv1880WqgQxiXuhqkxkhCwgefQ0s9xrjEslLvM1U=";
};
# Add $out/share/jupyter to the list of paths that are used to search for
@@ -85,6 +85,7 @@ in buildPythonPackage rec {
'';
nativeCheckInputs = [
flaky
ipywidgets
pyppeteer
pytestCheckHook
@@ -16,14 +16,14 @@
buildPythonPackage rec {
pname = "notebook";
version = "7.0.1";
version = "7.0.2";
disabled = pythonOlder "3.8";
format = "pyproject";
src = fetchPypi {
inherit pname version;
hash = "sha256-LhatTmPqiffvviEu58FpP8+lq1X/73UEdTD3SvS9kmw=";
hash = "sha256-1w1qB0GMgpvV9UM3zpk7cQUmHZAm+dP+aOm4qhog2po=";
};
postPatch = ''