1{ lib, buildPythonPackage, fetchPypi, isPy27
2, mock
3, nbformat
4, pytest
5, pyyaml
6}:
7
8buildPythonPackage rec {
9 pname = "jupytext";
10 version = "1.5.2";
11
12 src = fetchPypi {
13 inherit pname version;
14 sha256 = "1cebc9f5975b4c08db3de6d7d61b35f8c33a24cf2c8c04eee7b8a7aab8ddc39b";
15 };
16
17 propagatedBuildInputs = [
18 pyyaml
19 nbformat
20 ] ++ lib.optionals isPy27 [ mock ]; # why they put it in install_requires, who knows
21
22 checkInputs = [
23 pytest
24 ];
25
26 # requires test notebooks which are not shipped with the pypi release
27 # also, pypi no longer includes tests
28 doCheck = false;
29 checkPhase = ''
30 pytest
31 '';
32
33 meta = with lib; {
34 broken = true;
35 description = "Jupyter notebooks as Markdown documents, Julia, Python or R scripts";
36 homepage = "https://github.com/mwouts/jupytext";
37 license = licenses.mit;
38 maintainers = with maintainers; [ timokau ];
39 };
40}