sageWithDoc: 10.6 -> 10.7 (#446708)

authored by Mauricio Collares and committed by GitHub 0ca12ece 4d6af8d6

+22 -72
+2 -34
pkgs/by-name/sa/sage/patches/sphinx-docbuild-subprocesses.patch
··· 1 1 diff --git a/src/sage_docbuild/builders.py b/src/sage_docbuild/builders.py 2 - index ab39d93c280..e6501c083d5 100644 2 + index 91035a01f1c..24f3d0c7c12 100644 3 3 --- a/src/sage_docbuild/builders.py 4 4 +++ b/src/sage_docbuild/builders.py 5 - @@ -106,31 +106,6 @@ def builder_helper(type): 6 - """ 7 - Return a function which builds the documentation for 8 - output type ``type``. 9 - - 10 - - TESTS: 11 - - 12 - - Check that :issue:`25161` has been resolved:: 13 - - 14 - - sage: from sage_docbuild.builders import DocBuilder 15 - - sage: from sage_docbuild.__main__ import setup_parser 16 - - sage: DocBuilder._options = setup_parser().parse_args([]) # builder_helper needs _options to be set 17 - - 18 - - sage: import sage_docbuild.sphinxbuild 19 - - sage: def raiseBaseException(): 20 - - ....: raise BaseException("abort pool operation") 21 - - sage: original_runsphinx, sage_docbuild.sphinxbuild.runsphinx = sage_docbuild.sphinxbuild.runsphinx, raiseBaseException 22 - - 23 - - sage: from sage.misc.temporary_file import tmp_dir 24 - - sage: os.environ['SAGE_DOC'] = tmp_dir() 25 - - sage: sage.env.var('SAGE_DOC') # random 26 - - sage: from sage_docbuild.builders import builder_helper, build_ref_doc 27 - - sage: from sage_docbuild.builders import _build_many as build_many 28 - - sage: helper = builder_helper("html") 29 - - sage: try: # optional - sagemath_doc_html 30 - - ....: build_many(build_ref_doc, [("docname", "en", "html", {})]) 31 - - ....: except Exception as E: 32 - - ....: "Non-exception during docbuild: abort pool operation" in str(E) 33 - - True 34 - """ 35 - def f(self, *args, **kwds): 36 - output_dir = self._output_dir(type) 37 - @@ -157,10 +132,9 @@ def builder_helper(type): 5 + @@ -130,10 +130,9 @@ def builder_helper(type): 38 6 logger.debug(build_command) 39 7 40 8 # Run Sphinx with Sage's special logger
+11 -32
pkgs/by-name/sa/sage/sage-src.nix
··· 2 2 stdenv, 3 3 lib, 4 4 fetchFromGitHub, 5 - fetchpatch, 6 5 fetchpatch2, 7 6 fetchurl, 8 7 }: ··· 13 12 # all get the same sources with the same patches applied. 14 13 15 14 stdenv.mkDerivation rec { 16 - version = "10.6"; 15 + version = "10.7"; 17 16 pname = "sage-src"; 18 17 19 18 src = fetchFromGitHub { 20 19 owner = "sagemath"; 21 20 repo = "sage"; 22 21 rev = version; 23 - hash = "sha256-ZDYFq2lJXjnADFdX6y7sskaF0rkT5EIcdN8/bs00TlQ="; 22 + hash = "sha256-nYlBmKQ9TD5EAVvNwo8YzqAd5IUCpTU3kBTqUH21IxQ="; 24 23 }; 25 24 26 25 # contains essential files (e.g., setup.cfg) generated by the bootstrap script. ··· 28 27 configure-src = fetchurl { 29 28 # the hash below is the tagged commit's _parent_. it can also be found by looking for 30 29 # the "configure" asset at https://github.com/sagemath/sage/releases/tag/${version} 31 - url = "mirror://sageupstream/configure/configure-10741006a4794b7db82942db55b97033d5905431.tar.gz"; 32 - hash = "sha256-7LqY+vwBlyukDfcRtuR99vpC3hcBo8WRUuJjiFFq9xk="; 30 + url = "mirror://sageupstream/configure/configure-858268b40010e5ed6da13488ad0f52cda4d1f70e.tar.gz"; 31 + hash = "sha256-TsVX+wUWr+keCXmGQp1OHGXgNc7luajyGxfTwduSEtc="; 33 32 }; 34 33 35 34 # Patches needed because of particularities of nix or the way this is packaged. ··· 60 59 # compile libs/gap/element.pyx with -O1 61 60 # a more conservative version of https://github.com/sagemath/sage/pull/37951 62 61 ./patches/gap-element-crash.patch 62 + 63 + # https://github.com/sagemath/sage/pull/40895, positively reviewed 64 + (fetchpatch2 { 65 + name = "doctest-absolute-path.patch"; 66 + url = "https://github.com/sagemath/sage/commit/3de32dccd2e32e5452ca3adf5bd63cbacb64ba9d.patch?full_index=1"; 67 + hash = "sha256-rp+9d8Y6kifWzufE07GWU68txPn//w7uMn4LcpITaBs="; 68 + }) 63 69 ]; 64 70 65 71 # Patches needed because of package updates. We could just pin the versions of ··· 69 75 # should come from or be proposed to upstream. This list will probably never 70 76 # be empty since dependencies update all the time. 71 77 packageUpgradePatches = [ 72 - # https://github.com/sagemath/sage/pull/39737, positively reviewed 73 - (fetchpatch { 74 - name = "sphinx-8.2-update.patch"; 75 - url = "https://github.com/sagemath/sage/pull/39737/commits/4e485497fb5e20a056ffd2178360b88f482447d8.patch"; 76 - hash = "sha256-oIcFeol0SW5dE/iE6mbYyas3kXIjOwsG1k+h99R94x8="; 77 - }) 78 - 79 - # https://github.com/sagemath/sage/pull/40285, landed in 10.7.beta7 80 - (fetchpatch2 { 81 - name = "scipy-1.16-update.patch"; 82 - url = "https://github.com/sagemath/sage/commit/d0cbe9d353722580f98a327694f1a361c9b83ccd.patch?full_index=1"; 83 - hash = "sha256-uV2nttxCKDsNqMf1O+lUmuoiDrx7/CfiS00JBb9kiM8="; 84 - }) 85 - 86 - # https://github.com/sagemath/sage/pull/40156, landed in 10.7.beta5 87 - (fetchpatch2 { 88 - name = "cython-3.1-update.patch"; 89 - url = "https://github.com/sagemath/sage/commit/5ea8db28977ec113aec3c4c4b208d1783e3937a7.patch?full_index=1"; 90 - hash = "sha256-5DPPxMuidPpVHrjK8j0UVZzuwiVy9vQzFd6hBYwNAok="; 91 - }) 92 - 93 - # https://github.com/sagemath/sage/pull/40175, landed in 10.7.beta8 94 - (fetchpatch2 { 95 - name = "rpy2-3.6-update.patch"; 96 - url = "https://github.com/sagemath/sage/commit/db2d8db99d9a7dfa1972d534ecd89e3d2ba5c55b.patch?full_index=1"; 97 - hash = "sha256-6Bk0uGlKFsiDsgv+ljMC1YnmAT+g+he6aFNkpvw2on0="; 98 - }) 99 78 ]; 100 79 101 80 patches = nixPatches ++ bugfixPatches ++ packageUpgradePatches;
+9 -6
pkgs/by-name/sa/sage/sagedoc.nix
··· 20 20 chmod -R 755 "$SAGE_DOC_SRC_OVERRIDE" 21 21 ''; 22 22 23 - buildPhase = '' 24 - export SAGE_NUM_THREADS="$NIX_BUILD_CORES" 23 + preBuild = '' 24 + export SAGE_ROOT="${sage-with-env.env.lib.src}" 25 + export PATH="${sage-with-env}/bin:$PATH" 25 26 export HOME="$TMPDIR/sage_home" 26 27 mkdir -p "$HOME" 27 28 ··· 31 32 # jupyter-sphinx calls the sagemath jupyter kernel during docbuild 32 33 export JUPYTER_PATH=${jupyter-kernel-specs} 33 34 34 - ${sage-with-env}/bin/sage --docbuild \ 35 - --mathjax \ 36 - --no-pdf-links \ 37 - all html 35 + # the Makefile tries to guess SAGE_DOC, but in a buggy way (changed in 10.8) 36 + export SAGE_DOC="$SAGE_DOC_OVERRIDE" 37 + 38 + cd docsrc 38 39 ''; 40 + 41 + enableParallelBuilding = true; 39 42 40 43 installPhase = '' 41 44 cd "$SAGE_DOC_OVERRIDE"