From 52b9217b50379007c9de158d314e4d96134746f9 Mon Sep 17 00:00:00 2001 From: Timo Kaufmann Date: Thu, 16 Aug 2018 00:17:14 +0200 Subject: sage: 8.4.beta0 -> 8.4.beta1 --- .../math/sage/patches/dochtml-optional.patch | 127 --------------------- .../science/math/sage/patches/eclib-20180710.patch | 24 ---- .../math/sage/patches/pari-no-threads.patch | 18 --- .../science/math/sage/patches/test-in-tmpdir.patch | 31 ----- 4 files changed, 200 deletions(-) delete mode 100644 pkgs/applications/science/math/sage/patches/dochtml-optional.patch delete mode 100644 pkgs/applications/science/math/sage/patches/pari-no-threads.patch delete mode 100644 pkgs/applications/science/math/sage/patches/test-in-tmpdir.patch (limited to 'pkgs/applications/science/math/sage/patches') diff --git a/pkgs/applications/science/math/sage/patches/dochtml-optional.patch b/pkgs/applications/science/math/sage/patches/dochtml-optional.patch deleted file mode 100644 index a51e30312ed9..000000000000 --- a/pkgs/applications/science/math/sage/patches/dochtml-optional.patch +++ /dev/null @@ -1,127 +0,0 @@ -diff --git a/src/doc/common/conf.py b/src/doc/common/conf.py -index 25f94f7b7d..9f6139ea4a 100644 ---- a/src/doc/common/conf.py -+++ b/src/doc/common/conf.py -@@ -622,9 +622,9 @@ def call_intersphinx(app, env, node, contnode): - Check that the link from the thematic tutorials to the reference - manual is relative, see :trac:`20118`:: - -- sage: from sage.env import SAGE_DOC -- sage: thematic_index = os.path.join(SAGE_DOC, "html", "en", "thematic_tutorials", "index.html") -- sage: for line in open(thematic_index).readlines(): -+ sage: from sage.env import SAGE_DOC # optional - dochtml -+ sage: thematic_index = os.path.join(SAGE_DOC, "html", "en", "thematic_tutorials", "index.html") # optional - dochtml -+ sage: for line in open(thematic_index).readlines(): # optional - dochtml - ....: if "padics" in line: - ....: sys.stdout.write(line) -
  • Introduction to the -adics
  • -diff --git a/src/sage/doctest/control.py b/src/sage/doctest/control.py -index 4236fd05e0..8e499cbaf7 100644 ---- a/src/sage/doctest/control.py -+++ b/src/sage/doctest/control.py -@@ -87,7 +87,7 @@ class DocTestDefaults(SageObject): - self.sagenb = False - self.long = False - self.warn_long = None -- self.optional = set(['sage']) | auto_optional_tags -+ self.optional = set(['sage', 'dochtml']) | auto_optional_tags - self.randorder = None - self.global_iterations = 1 # sage-runtests default is 0 - self.file_iterations = 1 # sage-runtests default is 0 -@@ -343,7 +343,8 @@ class DocTestController(SageObject): - if not optionaltag_regex.search(o): - raise ValueError('invalid optional tag {!r}'.format(o)) - -- options.optional |= auto_optional_tags -+ if "sage" in options.optional: -+ options.optional |= auto_optional_tags - - self.options = options - self.files = args -@@ -741,7 +742,7 @@ class DocTestController(SageObject): - sage: DC = DocTestController(DD, [dirname]) - sage: DC.expand_files_into_sources() - sage: sorted(DC.sources[0].options.optional) # abs tol 1 -- ['guava', 'magma', 'py3'] -+ ['guava', 'magma'] - - We check that files are skipped appropriately:: - -@@ -968,7 +969,7 @@ class DocTestController(SageObject): - sage: from sage.doctest.control import DocTestDefaults, DocTestController - sage: DC = DocTestController(DocTestDefaults(), []) - sage: DC._optional_tags_string() -- 'sage' -+ 'dochtml,sage' - sage: DC = DocTestController(DocTestDefaults(optional="all,and,some,more"), []) - sage: DC._optional_tags_string() - 'all' -diff --git a/src/sage/misc/sagedoc.py b/src/sage/misc/sagedoc.py -index 9255aa848f..cc4712d3ec 100644 ---- a/src/sage/misc/sagedoc.py -+++ b/src/sage/misc/sagedoc.py -@@ -18,9 +18,9 @@ TESTS: - Check that argspecs of extension function/methods appear correctly, - see :trac:`12849`:: - -- sage: from sage.env import SAGE_DOC -- sage: docfilename = os.path.join(SAGE_DOC, 'html', 'en', 'reference', 'calculus', 'sage', 'symbolic', 'expression.html') -- sage: with open(docfilename) as fobj: -+ sage: from sage.env import SAGE_DOC # optional - dochtml -+ sage: docfilename = os.path.join(SAGE_DOC, 'html', 'en', 'reference', 'calculus', 'sage', 'symbolic', 'expression.html') # optional - dochtml -+ sage: with open(docfilename) as fobj: # optional - dochtml - ....: for line in fobj: - ....: if "#sage.symbolic.expression.Expression.numerical_approx" in line: - ....: print(line) -@@ -790,11 +790,12 @@ def _search_src_or_doc(what, string, extra1='', extra2='', extra3='', - - :: - -- sage: len(_search_src_or_doc('src', r'matrix\(', 'incidence_structures', 'self', 'combinat', interact=False).splitlines()) > 1 -+ sage: from sage.misc.sagedoc import _search_src_or_doc # optional - dochtml -+ sage: len(_search_src_or_doc('src', r'matrix\(', 'incidence_structures', 'self', 'combinat', interact=False).splitlines()) > 1 # optional - dochtml - True -- sage: 'abvar/homology' in _search_src_or_doc('doc', 'homology', 'variety', interact=False) # long time (4s on sage.math, 2012) -+ sage: 'abvar/homology' in _search_src_or_doc('doc', 'homology', 'variety', interact=False) # optional - dochtml, long time (4s on sage.math, 2012) - True -- sage: 'divisors' in _search_src_or_doc('src', '^ *def prime', interact=False) -+ sage: 'divisors' in _search_src_or_doc('src', '^ *def prime', interact=False) # optional - dochtml - True - """ - # process keywords -@@ -1160,9 +1161,9 @@ def search_doc(string, extra1='', extra2='', extra3='', extra4='', - counting the length of ``search_doc('tree', - interact=False).splitlines()`` gives the number of matches. :: - -- sage: len(search_doc('tree', interact=False).splitlines()) > 4000 # long time -+ sage: len(search_doc('tree', interact=False).splitlines()) > 4000 # optional - dochtml, long time - True -- sage: len(search_doc('tree', whole_word=True, interact=False).splitlines()) < 2000 # long time -+ sage: len(search_doc('tree', whole_word=True, interact=False).splitlines()) < 2000 # optional - dochtml, long time - True - """ - return _search_src_or_doc('doc', string, extra1=extra1, extra2=extra2, -@@ -1332,9 +1333,9 @@ class _sage_doc: - - EXAMPLES:: - -- sage: browse_sage_doc._open("reference", testing=True)[0] # indirect doctest -+ sage: browse_sage_doc._open("reference", testing=True)[0] # optional - dochtml, indirect doctest - 'http://localhost:8000/doc/live/reference/index.html' -- sage: browse_sage_doc(identity_matrix, 'rst')[-107:-47] -+ sage: browse_sage_doc(identity_matrix, 'rst')[-107:-47] # optional - dochtml - 'Full MatrixSpace of 3 by 3 sparse matrices over Integer Ring' - """ - def __init__(self): -@@ -1494,9 +1495,9 @@ class _sage_doc: - - EXAMPLES:: - -- sage: browse_sage_doc._open("reference", testing=True)[0] -+ sage: browse_sage_doc._open("reference", testing=True)[0] # optional - dochtml - 'http://localhost:8000/doc/live/reference/index.html' -- sage: browse_sage_doc._open("tutorial", testing=True)[1] -+ sage: browse_sage_doc._open("tutorial", testing=True)[1] # optional - dochtml - '.../html/en/tutorial/index.html' - """ - url = self._base_url + os.path.join(name, "index.html") diff --git a/pkgs/applications/science/math/sage/patches/eclib-20180710.patch b/pkgs/applications/science/math/sage/patches/eclib-20180710.patch index d06e1e6cedf2..986ae42aeb62 100644 --- a/pkgs/applications/science/math/sage/patches/eclib-20180710.patch +++ b/pkgs/applications/science/math/sage/patches/eclib-20180710.patch @@ -14,27 +14,3 @@ index 4417b59276..ae57ca2991 100644 """ global instances try: -diff --git a/src/sage/libs/eclib/wrap.cpp b/src/sage/libs/eclib/wrap.cpp -index 5fd5693b53..d12468faa8 100644 ---- a/src/sage/libs/eclib/wrap.cpp -+++ b/src/sage/libs/eclib/wrap.cpp -@@ -133,8 +133,8 @@ char* Curvedata_isogeny_class(struct Curvedata* E, int verbose) - - - int mw_process(struct Curvedata* curve, struct mw* m, -- const struct bigint* x, const struct bigint* y, -- const struct bigint* z, int sat) -+ const bigint* x, const bigint* y, -+ const bigint* z, int sat) - { - Point P(*curve, *x, *y, *z); - if (!P.isvalid()) -@@ -188,7 +188,7 @@ int mw_rank(struct mw* m) - } - - /* Returns index and unsat long array, which user must deallocate */ --int mw_saturate(struct mw* m, struct bigint* index, char** unsat, -+int mw_saturate(struct mw* m, bigint* index, char** unsat, - long sat_bd, int odd_primes_only) - { - vector v; diff --git a/pkgs/applications/science/math/sage/patches/pari-no-threads.patch b/pkgs/applications/science/math/sage/patches/pari-no-threads.patch deleted file mode 100644 index 13b47dbdd31b..000000000000 --- a/pkgs/applications/science/math/sage/patches/pari-no-threads.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/src/sage/libs/pari/__init__.py b/src/sage/libs/pari/__init__.py -index e451766474..77eda66097 100644 ---- a/src/sage/libs/pari/__init__.py -+++ b/src/sage/libs/pari/__init__.py -@@ -205,6 +205,13 @@ def _get_pari_instance(): - # messages in Sage. - P.default("debugmem", 0) - -+ # Make sure pari doesn't use threads, regardless of how it was compiled. -+ # Threads cause some doctest failures (memory issues). Those could probably -+ # be solved without disabling threads. But that would require figuring out -+ # some sensible values for `threadsizemax`. See -+ # https://pari.math.u-bordeaux.fr/dochtml/html/GP_defaults.html -+ P.default("nbthreads", 1) -+ - return P - - pari = _get_pari_instance() diff --git a/pkgs/applications/science/math/sage/patches/test-in-tmpdir.patch b/pkgs/applications/science/math/sage/patches/test-in-tmpdir.patch deleted file mode 100644 index febab3702771..000000000000 --- a/pkgs/applications/science/math/sage/patches/test-in-tmpdir.patch +++ /dev/null @@ -1,31 +0,0 @@ -diff --git a/src/sage/repl/ipython_kernel/install.py b/src/sage/repl/ipython_kernel/install.py -index aa23c8405d..8a87de0591 100644 ---- a/src/sage/repl/ipython_kernel/install.py -+++ b/src/sage/repl/ipython_kernel/install.py -@@ -112,7 +112,7 @@ class SageKernelSpec(object): - EXAMPLES:: - - sage: from sage.repl.ipython_kernel.install import SageKernelSpec -- sage: spec = SageKernelSpec() -+ sage: spec = SageKernelSpec(prefix = tmp_dir()) - sage: spec.use_local_mathjax() - sage: mathjax = os.path.join(spec.nbextensions_dir, 'mathjax') - sage: os.path.isdir(mathjax) -@@ -129,7 +129,7 @@ class SageKernelSpec(object): - EXAMPLES:: - - sage: from sage.repl.ipython_kernel.install import SageKernelSpec -- sage: spec = SageKernelSpec() -+ sage: spec = SageKernelSpec(prefix = tmp_dir()) - sage: spec.use_local_jsmol() - sage: jsmol = os.path.join(spec.nbextensions_dir, 'jsmol') - sage: os.path.isdir(jsmol) -@@ -146,7 +146,7 @@ class SageKernelSpec(object): - EXAMPLES:: - - sage: from sage.repl.ipython_kernel.install import SageKernelSpec -- sage: spec = SageKernelSpec() -+ sage: spec = SageKernelSpec(prefix = tmp_dir()) - sage: spec.use_local_threejs() - sage: threejs = os.path.join(spec.nbextensions_dir, 'threejs') - sage: os.path.isdir(threejs) -- cgit 1.4.1