2021-03-23 19:22:30 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2022-02-10 20:34:41 +00:00
|
|
|
, python
|
2021-03-23 19:22:30 +00:00
|
|
|
, notebook
|
|
|
|
, pythonOlder
|
|
|
|
, jupyter_server
|
|
|
|
, pytestCheckHook
|
|
|
|
, pytest-tornasync
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "nbclassic";
|
2022-02-10 20:34:41 +00:00
|
|
|
version = "0.3.5";
|
2021-06-28 23:13:55 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
2021-03-23 19:22:30 +00:00
|
|
|
|
|
|
|
# tests only on github
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jupyterlab";
|
|
|
|
repo = pname;
|
2022-02-10 20:34:41 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "1d0x7nwsaw5qjw4iaylc2sxlpiq3hlg9sy3i2nh7sn3wckwl76lc";
|
2021-03-23 19:22:30 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ jupyter_server notebook ];
|
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
preCheck = ''
|
|
|
|
cd nbclassic
|
|
|
|
mv conftest.py tests
|
|
|
|
cd tests
|
|
|
|
|
|
|
|
export PYTHONPATH=$out/${python.sitePackages}:$PYTHONPATH
|
|
|
|
'';
|
2021-03-23 19:22:30 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
pytest-tornasync
|
|
|
|
];
|
|
|
|
|
2021-05-28 09:39:13 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2021-03-23 19:22:30 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Jupyter lab environment notebook server extension.";
|
|
|
|
license = with licenses; [ bsd3 ];
|
|
|
|
homepage = "https://github.com/jupyterlab/nbclassic";
|
|
|
|
maintainers = [ maintainers.elohmeier ];
|
|
|
|
};
|
|
|
|
}
|