at master 1.9 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchPypi, 5 pytestCheckHook, 6 pythonAtLeast, 7 pythonOlder, 8 defusedxml, 9 setuptools, 10 sphinx, 11 typing-extensions, 12 unidecode, 13}: 14 15buildPythonPackage rec { 16 pname = "uqbar"; 17 version = "0.9.5"; 18 pyproject = true; 19 20 disabled = pythonOlder "3.8"; 21 22 src = fetchPypi { 23 inherit pname version; 24 hash = "sha256-MHSnuPiJu2p3NiG/bV6qFUO90xQEFcyQrcxMY0hw8E8="; 25 }; 26 27 postPatch = '' 28 sed -i pyproject.toml \ 29 -e '/"black"/d' \ 30 -e "/--cov/d" 31 ''; 32 33 nativeBuildInputs = [ setuptools ]; 34 35 propagatedBuildInputs = [ 36 unidecode 37 sphinx 38 ]; 39 40 nativeCheckInputs = [ pytestCheckHook ]; 41 42 checkInputs = [ 43 defusedxml 44 typing-extensions 45 ]; 46 47 disabledTests = [ 48 # UnboundLocalError: local variable 'output_path' referenced before assignment 49 "test_01" 50 # AssertionError: assert False 51 "test_sphinx_book_html_cached" 52 # FileNotFoundError: [Errno 2] No such file or directory: 'unflatten' 53 "test_sphinx_style_html" 54 # assert not ["\x1b[91mWARNING: dot command 'dot' cannot be run (needed for 55 # graphviz output), check the graphviz_dot setting\x1b[39;49;00m"] 56 "test_sphinx_style_latex" 57 ] 58 ++ lib.optional (pythonAtLeast "3.11") [ 59 # assert not '\x1b[91m/build/uqbar-0.7.0/tests/fake_package/enums.py:docstring 60 "test_sphinx_style" 61 ] 62 ++ lib.optional (pythonAtLeast "3.12") [ 63 # https://github.com/josiah-wolf-oberholtzer/uqbar/issues/93 64 "objects.get_vars" 65 ]; 66 67 pythonImportsCheck = [ "uqbar" ]; 68 69 meta = with lib; { 70 description = "Tools for creating Sphinx and Graphviz documentation"; 71 homepage = "https://github.com/josiah-wolf-oberholtzer/uqbar"; 72 changelog = "https://github.com/josiah-wolf-oberholtzer/uqbar/releases/tag/v${version}"; 73 license = licenses.mit; 74 maintainers = with maintainers; [ davisrichard437 ]; 75 }; 76}