nixpkgs/pkgs/development/python-modules/notebook/default.nix

61 lines
1.2 KiB
Nix
Raw Normal View History

{ lib
, buildPythonPackage
, fetchPypi
, nose
2017-10-23 12:40:02 +01:00
, nose_warnings_filters
, glibcLocales
2017-10-23 12:40:02 +01:00
, isPy3k
, mock
, jinja2
, tornado
, ipython_genutils
, traitlets
, jupyter_core
, jupyter_client
, nbformat
, nbconvert
, ipykernel
, terminado
, requests
, pexpect
}:
buildPythonPackage rec {
pname = "notebook";
2017-12-30 11:25:00 +00:00
version = "5.2.2";
name = "${pname}-${version}";
src = fetchPypi {
inherit pname version;
2017-12-30 11:25:00 +00:00
sha256 = "7bb54fb61b9c5426bc116f840541b973431198e00ea2896122d05fc122dbbd67";
};
2017-10-23 12:40:02 +01:00
LC_ALL = "en_US.utf8";
2017-10-23 12:40:02 +01:00
buildInputs = [ nose glibcLocales ]
++ (if isPy3k then [ nose_warnings_filters ] else [ mock ]);
2017-10-23 12:40:02 +01:00
propagatedBuildInputs = [
jinja2 tornado ipython_genutils traitlets jupyter_core
jupyter_client nbformat nbconvert ipykernel terminado requests pexpect
];
2017-10-23 12:40:02 +01:00
# disable warning_filters
preCheck = lib.optionalString (!isPy3k) ''
echo "" > setup.cfg
cat setup.cfg
'';
checkPhase = ''
2017-10-23 12:40:02 +01:00
runHook preCheck
mkdir tmp
HOME=tmp nosetests -v
'';
meta = {
description = "The Jupyter HTML notebook is a web-based notebook environment for interactive computing";
homepage = http://jupyter.org/;
license = lib.licenses.bsd3;
2017-10-23 12:40:02 +01:00
maintainers = with lib.maintainers; [ fridh globin ];
};
2017-10-23 12:40:02 +01:00
}