2018-11-26 20:20:05 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2023-03-03 17:47:17 +00:00
|
|
|
, pythonOlder
|
2024-03-10 05:51:04 +00:00
|
|
|
, setuptools
|
2018-11-26 20:20:05 +00:00
|
|
|
, coverage
|
|
|
|
, ipykernel
|
2021-10-15 10:33:48 +00:00
|
|
|
, jupyter-client
|
2018-11-26 20:20:05 +00:00
|
|
|
, nbformat
|
2021-05-21 19:43:41 +00:00
|
|
|
, pytestCheckHook
|
2018-11-26 20:20:05 +00:00
|
|
|
, pytest
|
|
|
|
, glibcLocales
|
|
|
|
, matplotlib
|
|
|
|
, sympy
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "nbval";
|
2024-03-08 01:41:09 +00:00
|
|
|
version = "0.11.0";
|
2024-03-10 05:51:04 +00:00
|
|
|
pyproject = true;
|
2023-03-03 17:47:17 +00:00
|
|
|
|
2024-03-10 05:51:04 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2018-11-26 20:20:05 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-03-08 01:41:09 +00:00
|
|
|
hash = "sha256-d8lXl2B7CpaLq9JZfuNJQQLSXDrTdDXeu9rA5G43kJQ=";
|
2018-11-26 20:20:05 +00:00
|
|
|
};
|
|
|
|
|
2021-11-09 22:26:02 +00:00
|
|
|
buildInputs = [
|
|
|
|
glibcLocales
|
2019-07-16 21:20:55 +00:00
|
|
|
];
|
2018-11-26 20:20:05 +00:00
|
|
|
|
2024-03-10 05:51:04 +00:00
|
|
|
build-system = [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
|
|
|
dependencies = [
|
2019-07-16 21:20:55 +00:00
|
|
|
coverage
|
|
|
|
ipykernel
|
2021-10-15 10:33:48 +00:00
|
|
|
jupyter-client
|
2019-07-16 21:20:55 +00:00
|
|
|
nbformat
|
|
|
|
pytest
|
|
|
|
];
|
2018-11-26 20:20:05 +00:00
|
|
|
|
2023-01-21 12:00:00 +00:00
|
|
|
nativeCheckInputs = [
|
2021-11-09 22:26:02 +00:00
|
|
|
pytestCheckHook
|
|
|
|
matplotlib
|
|
|
|
sympy
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
"tests/test_ignore.py"
|
2021-05-21 19:43:41 +00:00
|
|
|
# These are the main tests but they're fragile so skip them. They error
|
|
|
|
# whenever matplotlib outputs any unexpected warnings, e.g. deprecation
|
|
|
|
# warnings.
|
2021-11-09 22:26:02 +00:00
|
|
|
"tests/test_unit_tests_in_notebooks.py"
|
2021-05-21 19:43:41 +00:00
|
|
|
# Impure
|
2021-11-09 22:26:02 +00:00
|
|
|
"tests/test_timeouts.py"
|
|
|
|
# No value for us
|
|
|
|
"tests/test_coverage.py"
|
2023-03-03 17:47:17 +00:00
|
|
|
# nbdime marked broken
|
|
|
|
"tests/test_nbdime_reporter.py"
|
2021-05-21 19:43:41 +00:00
|
|
|
];
|
2018-11-26 20:20:05 +00:00
|
|
|
|
2019-09-14 20:24:57 +00:00
|
|
|
# Some of the tests use localhost networking.
|
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2021-11-09 22:26:02 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"nbval"
|
|
|
|
];
|
|
|
|
|
2018-11-26 20:20:05 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "A py.test plugin to validate Jupyter notebooks";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/computationalmodelling/nbval";
|
2024-03-10 05:51:04 +00:00
|
|
|
changelog = "https://github.com/computationalmodelling/nbval/releases/tag/${version}";
|
2018-11-26 20:20:05 +00:00
|
|
|
license = licenses.bsd3;
|
2023-06-30 15:53:25 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2018-11-26 20:20:05 +00:00
|
|
|
};
|
|
|
|
}
|