Merge pull request #233447 from SuperSandro2000/hypothesis-doc-pasthru

python310Packages.hypothesis: move documentation to passthru to reduce dependencies

authored by

Sandro and committed by
GitHub
1f49db77 8d494834

+34 -26
-3
pkgs/applications/misc/privacyidea/default.nix
··· 141 141 sphinxHook = null; 142 142 sphinx-better-theme = null; 143 143 }).overridePythonAttrs dropDocOutput; 144 - hypothesis = super.hypothesis.override { 145 - enableDocumentation = false; 146 - }; 147 144 pyjwt = (super.pyjwt.override { 148 145 sphinxHook = null; 149 146 sphinx-rtd-theme = null;
+1 -2
pkgs/development/python-modules/chardet/default.nix
··· 23 23 ]; 24 24 25 25 nativeCheckInputs = [ 26 - # "hypothesis" indirectly depends on chardet to build its documentation. 27 - (hypothesis.override { enableDocumentation = false; }) 26 + hypothesis 28 27 pytestCheckHook 29 28 ]; 30 29
+1 -2
pkgs/development/python-modules/cryptography/default.nix
··· 72 72 73 73 nativeCheckInputs = [ 74 74 cryptography-vectors 75 - # "hypothesis" indirectly depends on cryptography to build its documentation 76 - (hypothesis.override { enableDocumentation = false; }) 75 + hypothesis 77 76 iso8601 78 77 pretend 79 78 py
+28 -11
pkgs/development/python-modules/hypothesis/default.nix
··· 8 8 , doCheck ? true 9 9 , pytestCheckHook 10 10 , pytest-xdist 11 + , python 11 12 , sortedcontainers 13 + , stdenv 12 14 , pythonOlder 13 15 , sphinxHook 14 16 , sphinx-rtd-theme 15 17 , sphinx-hoverxref 16 18 , sphinx-codeautolink 17 19 , tzdata 18 - # Used to break internal dependency loop. 19 - , enableDocumentation ? true 20 20 }: 21 21 22 22 buildPythonPackage rec { 23 23 pname = "hypothesis"; 24 24 version = "6.68.2"; 25 - outputs = [ "out" ] ++ lib.optional enableDocumentation "doc"; 25 + outputs = [ "out" ]; 26 26 format = "setuptools"; 27 27 28 28 disabled = pythonOlder "3.7"; ··· 49 49 50 50 postUnpack = "sourceRoot=$sourceRoot/hypothesis-python"; 51 51 52 - nativeBuildInputs = lib.optionals enableDocumentation [ 53 - sphinxHook 54 - sphinx-rtd-theme 55 - sphinx-hoverxref 56 - sphinx-codeautolink 57 - ]; 58 - 59 52 propagatedBuildInputs = [ 60 53 attrs 61 54 sortedcontainers ··· 67 60 pexpect 68 61 pytest-xdist 69 62 pytestCheckHook 70 - ] ++ lib.optionals (isPyPy) [ 63 + ] ++ lib.optionals isPyPy [ 71 64 tzdata 72 65 ]; 73 66 ··· 85 78 pythonImportsCheck = [ 86 79 "hypothesis" 87 80 ]; 81 + 82 + passthru = { 83 + doc = stdenv.mkDerivation { 84 + # Forge look and feel of multi-output derivation as best as we can. 85 + # 86 + # Using 'outputs = [ "doc" ];' breaks a lot of assumptions. 87 + name = "${pname}-${version}-doc"; 88 + inherit src pname version; 89 + 90 + postInstallSphinx = '' 91 + mv $out/share/doc/* $out/share/doc/python$pythonVersion-$pname-$version 92 + ''; 93 + 94 + nativeBuildInputs = [ 95 + sphinxHook 96 + sphinx-rtd-theme 97 + sphinx-hoverxref 98 + sphinx-codeautolink 99 + ]; 100 + 101 + inherit (python) pythonVersion; 102 + inherit meta; 103 + }; 104 + }; 88 105 89 106 meta = with lib; { 90 107 description = "Library for property based testing";
+1 -2
pkgs/development/python-modules/iso8601/default.nix
··· 25 25 ]; 26 26 27 27 nativeCheckInputs = [ 28 - # "hypothesis" indirectly depends on iso8601 to build its documentation 29 - (hypothesis.override { enableDocumentation = false; }) 28 + hypothesis 30 29 pytestCheckHook 31 30 pytz 32 31 ];
+1 -2
pkgs/development/python-modules/numpy/default.nix
··· 76 76 77 77 nativeCheckInputs = [ 78 78 pytest 79 - # "hypothesis" indirectly depends on numpy to build its documentation. 80 - (hypothesis.override { enableDocumentation = false; }) 79 + hypothesis 81 80 typing-extensions 82 81 ]; 83 82
+1 -2
pkgs/development/python-modules/pandas/default.nix
··· 44 44 45 45 nativeCheckInputs = [ 46 46 glibcLocales 47 - # hypothesis indirectly depends on pandas to build its documentation 48 - (hypothesis.override { enableDocumentation = false; }) 47 + hypothesis 49 48 jinja2 50 49 pytest-asyncio 51 50 pytest-xdist
+1 -2
pkgs/development/python-modules/twisted/default.nix
··· 159 159 nativeCheckInputs = [ 160 160 git 161 161 glibcLocales 162 - # "hypothesis" indirectly depends on twisted to build its documentation. 163 - (hypothesis.override { enableDocumentation = false; }) 162 + hypothesis 164 163 pyhamcrest 165 164 ] 166 165 ++ passthru.optional-dependencies.conch