summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntonio Rojas2020-06-26 19:36:48 +0200
committerAntonio Rojas2020-06-26 19:36:48 +0200
commit59fc031252f34a223e3a0da9fbef1932d01e83c2 (patch)
treeaab88c7d37e8780e4de4be9d78ee4f78a84e5aaf
parent28216922114c2ae8d5ad1db453d80cbbef8c402d (diff)
downloadaur-59fc031252f34a223e3a0da9fbef1932d01e83c2.tar.gz
Drop merged patches
-rw-r--r--.SRCINFO16
-rw-r--r--PKGBUILD24
-rw-r--r--package.patch4
-rw-r--r--sagemath-ecl-20.04.patch292
-rw-r--r--sagemath-gap-4.11.patch4
-rw-r--r--sagemath-no-dict-sorting.patch62
-rw-r--r--sagemath-pari-2.11.3.patch252
-rw-r--r--sagemath-sphinx-3.patch521
-rw-r--r--sagemath-sympy-1.6.patch60
9 files changed, 88 insertions, 1147 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 6270e4e27386..c92b55d6ccdc 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = sagemath-git
pkgdesc = Open Source Mathematics Software, free alternative to Magma, Maple, Mathematica, and Matlab
- pkgver = 9.2.beta1.r0.ge2dcdeeabb
+ pkgver = 9.2.beta2.r0.g69d2b2da28
pkgrel = 1
url = http://www.sagemath.org
arch = x86_64
@@ -100,31 +100,23 @@ pkgbase = sagemath-git
source = sagemath-cremona.patch
source = sagemath-singular-4.1.2.patch
source = sagemath-ecl-20.04.patch
- source = sagemath-no-dict-sorting.patch
source = sagemath-ipython7.patch
source = sagemath-python-3.8.patch
source = sagemath-pexpect-4.8.patch
source = sagemath-gap-4.11.patch
- source = sagemath-pari-2.11.3.patch
- source = sagemath-sphinx-3.patch
- source = sagemath-sympy-1.6.patch
source = sagemath-flint-2.6.patch
source = sagemath-cython-0.29.20.patch
sha256sums = SKIP
- sha256sums = 5034676c4ce46181723f261d6bd180a795adea417f485c5e3e361b3aaef498ec
+ sha256sums = 5dbff7afecbc78e8ff7749b2ac929e8d2104e205bb2193f05a9687ce5ce65cf4
sha256sums = d6d8dd7d75e29a9ddbbb0da6fe18f86ee3ff49aad4af71104da38a8fa0d4c3db
sha256sums = 77aa8e99aae5da74a9486f01b603a0b5d224c3d13e9d9fab681fb71a6af149f1
sha256sums = 937074fa7a8a4e2aba9ea77ec622fe937985a1a9176c48460d51325ee877a4f5
sha256sums = 6f98488d0eb3a12b958cd1a34f85b7bee950ac756430371c1e134e564cbbf7d3
- sha256sums = 1fabc86d066310988a90083aaedceb9690822df8ff80c16501692231daa96e33
- sha256sums = f9721c66d1a0267bb19923f5084d40f8121fcada6db1d1c37484dab70b655544
+ sha256sums = c50b6bd6ee6e00fc15ec267ac3187e234e5564f6c346c74d7ddaa5dc5f1fcd22
sha256sums = b2a7055bc380c1d86a9514540d985fc4bce3cea1ea865e13642f11b1bf0f6e50
sha256sums = e55bb5df7d6ce65fc9d124b6b59407071f0c55d88f730e9467398f10cc87e66d
sha256sums = 5e6d1aa34959bd4369bd08a80648a5c7bc2d38e72c97e9a5f986e91f8a7aca07
- sha256sums = f6b3f52748d0f692f109c29724b402149b74960d8954e244ab770c85af832b6c
- sha256sums = 688345dd88174cc82a196a9ecace86f3b4f28bb2fae2d7196a40a76ff724f92e
- sha256sums = c9fa4f136a8e4fa9832524bb0ee4a7fbb3c6e992595a3b10c7c627ba9161b4ce
- sha256sums = ade7f86abc8b04b6a01c1a495b644a034d27bacdfdfa62813f4f8945bb96a8fe
+ sha256sums = aeb6bb7a8d40f3d3b3547ee5f1e67e876051d9463cd1e0000b497c4d0f3e2fe9
sha256sums = b881d4a6867a6f5360fd204e6a86fd27c6177c539b06f521402e2bcb5a6209cd
sha256sums = 6bc0eb8a54800d745474d7d371efedfd96838574f32fb9e2714ab268ccad2df7
diff --git a/PKGBUILD b/PKGBUILD
index 87472540740a..66f2716a81a1 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -7,7 +7,7 @@
pkgbase=sagemath-git
pkgname=(sagemath-git sagemath-jupyter-git)
-pkgver=9.2.beta1.r0.ge2dcdeeabb
+pkgver=9.2.beta2.r0.g69d2b2da28
pkgrel=1
pkgdesc="Open Source Mathematics Software, free alternative to Magma, Maple, Mathematica, and Matlab"
arch=(x86_64)
@@ -41,31 +41,23 @@ source=(git://git.sagemath.org/sage.git#branch=develop
sagemath-cremona.patch
sagemath-singular-4.1.2.patch
sagemath-ecl-20.04.patch
- sagemath-no-dict-sorting.patch
sagemath-ipython7.patch
sagemath-python-3.8.patch
sagemath-pexpect-4.8.patch
sagemath-gap-4.11.patch
- sagemath-pari-2.11.3.patch
- sagemath-sphinx-3.patch
- sagemath-sympy-1.6.patch
sagemath-flint-2.6.patch
sagemath-cython-0.29.20.patch)
sha256sums=('SKIP'
- '5034676c4ce46181723f261d6bd180a795adea417f485c5e3e361b3aaef498ec'
+ '5dbff7afecbc78e8ff7749b2ac929e8d2104e205bb2193f05a9687ce5ce65cf4'
'd6d8dd7d75e29a9ddbbb0da6fe18f86ee3ff49aad4af71104da38a8fa0d4c3db'
'77aa8e99aae5da74a9486f01b603a0b5d224c3d13e9d9fab681fb71a6af149f1'
'937074fa7a8a4e2aba9ea77ec622fe937985a1a9176c48460d51325ee877a4f5'
'6f98488d0eb3a12b958cd1a34f85b7bee950ac756430371c1e134e564cbbf7d3'
- '1fabc86d066310988a90083aaedceb9690822df8ff80c16501692231daa96e33'
- 'f9721c66d1a0267bb19923f5084d40f8121fcada6db1d1c37484dab70b655544'
+ 'c50b6bd6ee6e00fc15ec267ac3187e234e5564f6c346c74d7ddaa5dc5f1fcd22'
'b2a7055bc380c1d86a9514540d985fc4bce3cea1ea865e13642f11b1bf0f6e50'
'e55bb5df7d6ce65fc9d124b6b59407071f0c55d88f730e9467398f10cc87e66d'
'5e6d1aa34959bd4369bd08a80648a5c7bc2d38e72c97e9a5f986e91f8a7aca07'
- 'f6b3f52748d0f692f109c29724b402149b74960d8954e244ab770c85af832b6c'
- '688345dd88174cc82a196a9ecace86f3b4f28bb2fae2d7196a40a76ff724f92e'
- 'c9fa4f136a8e4fa9832524bb0ee4a7fbb3c6e992595a3b10c7c627ba9161b4ce'
- 'ade7f86abc8b04b6a01c1a495b644a034d27bacdfdfa62813f4f8945bb96a8fe'
+ 'aeb6bb7a8d40f3d3b3547ee5f1e67e876051d9463cd1e0000b497c4d0f3e2fe9'
'b881d4a6867a6f5360fd204e6a86fd27c6177c539b06f521402e2bcb5a6209cd'
'6bc0eb8a54800d745474d7d371efedfd96838574f32fb9e2714ab268ccad2df7')
@@ -84,12 +76,6 @@ prepare(){
patch -p1 -i ../sagemath-singular-4.1.2.patch
# Fix build with ECL 20.04 https://trac.sagemath.org/ticket/22191
patch -p1 -i ../sagemath-ecl-20.04.patch
-# Fix doc build with sphinx 3 https://trac.sagemath.org/ticket/28856
- patch -p1 -i ../sagemath-sphinx-3.patch
-# Port to sympy 1.6 changes https://trac.sagemath.org/ticket/29730
- patch -p1 -i ../sagemath-sympy-1.6.patch
-# Sort dicts in doctests https://trac.sagemath.org/ticket/29042
- patch -p1 -i ../sagemath-no-dict-sorting.patch
# Fix segfault and tests with flint 2.6 https://trac.sagemath.org/ticket/29719
patch -p1 -i ../sagemath-flint-2.6.patch
@@ -110,8 +96,6 @@ prepare(){
sed -e 's|mathjax|mathjax2|g' -i src/sage/env.py
# Fix gap.version() and doctests with GAP 4.11
patch -p1 -i ../sagemath-gap-4.11.patch
-# Fix doctests with pari 2.11.3
- patch -p1 -i ../sagemath-pari-2.11.3.patch
# Fix crash with cython 0.29.20
patch -p1 -i ../sagemath-cython-0.29.20.patch
diff --git a/package.patch b/package.patch
index 225e9735cacb..0fdc09da1c44 100644
--- a/package.patch
+++ b/package.patch
@@ -1,13 +1,11 @@
--- src/module_list.py
+++ src/module_list.py
-@@ -525,12 +525,6 @@ ext_modules = [
+@@ -449,10 +449,6 @@ ext_modules = [
Extension('sage.libs.ecl',
sources = ["sage/libs/ecl.pyx"]),
- OptionalExtension("sage.libs.fes",
- ["sage/libs/fes.pyx"],
-- language = "c",
-- libraries = ['fes'],
- package = 'fes'),
-
Extension('sage.libs.flint.flint',
diff --git a/sagemath-ecl-20.04.patch b/sagemath-ecl-20.04.patch
index 9961f1dc443b..0a0ecfcc9ddf 100644
--- a/sagemath-ecl-20.04.patch
+++ b/sagemath-ecl-20.04.patch
@@ -62,15 +62,6 @@ diff --git a/src/sage/libs/ecl.pxd b/src/sage/libs/ecl.pxd
index 4dd273f..f0b30de 100644
--- a/src/sage/libs/ecl.pxd
+++ b/src/sage/libs/ecl.pxd
-@@ -30,7 +30,7 @@ cdef extern from "ecl/ecl.h":
- ctypedef long int cl_fixnum
- ctypedef cl_fixnum cl_narg
- ctypedef void *cl_object
-- ctypedef unsigned int cl_index
-+ ctypedef unsigned long int cl_index
-
- ctypedef enum ecl_option:
- ECL_OPT_INCREMENTAL_GC = 0,
@@ -39,7 +39,6 @@ cdef extern from "ecl/ecl.h":
ECL_OPT_TRAP_SIGINT,
ECL_OPT_TRAP_SIGILL,
@@ -87,29 +78,8 @@ index 4dd273f..f0b30de 100644
ECL_OPT_HEAP_SIZE,
ECL_OPT_HEAP_SAFETY_AREA,
ECL_OPT_THREAD_INTERRUPT_SIGNAL,
-@@ -127,6 +125,7 @@ cdef extern from "ecl/ecl.h":
- cl_object cl_cddr(cl_object x)
- cl_object cl_rplaca(cl_object x, cl_object v)
- cl_object cl_rplacd(cl_object x, cl_object v)
-+ cl_object ecl_list1(cl_object a)
-
- # string parsing and string IO
-
-@@ -147,6 +146,10 @@ cdef extern from "ecl/ecl.h":
- int ecl_nvalues "NVALUES"
- cl_object ecl_values "VALUES"(int n)
-
-- #Common Lisp "EQUAL" compatible hash function
-+ # Common Lisp "EQUAL" compatible hash function
-
- cl_object cl_sxhash(cl_object key)
-+
-+ # symbols
-+
-+ cl_object ecl_make_symbol(const char *name, const char *package)
-\ No newline at end of file
diff --git a/src/sage/libs/ecl.pyx b/src/sage/libs/ecl.pyx
-index 1f05f4a..978e19b 100644
+index e408866..fa24ac0 100644
--- a/src/sage/libs/ecl.pyx
+++ b/src/sage/libs/ecl.pyx
@@ -15,7 +15,7 @@ Library interface to Embeddable Common Lisp (ECL)
@@ -121,7 +91,7 @@ index 1f05f4a..978e19b 100644
from libc.signal cimport raise_ as signal_raise
from posix.signal cimport sigaction, sigaction_t
cimport cysignals.signals
-@@ -47,9 +47,16 @@ cdef extern from "eclsig.h":
+@@ -47,9 +47,14 @@ cdef extern from "eclsig.h":
void ecl_sig_off()
cdef sigaction_t ecl_sigint_handler
cdef sigaction_t ecl_sigbus_handler
@@ -129,25 +99,13 @@ index 1f05f4a..978e19b 100644
cdef sigaction_t ecl_sigsegv_handler
cdef mpz_t ecl_mpz_from_bignum(cl_object obj)
cdef cl_object ecl_bignum_from_mpz(mpz_t num)
-+ cdef cl_object conditions_to_handle_clobj
-+ void safe_cl_boot(int argc, char** argv)
-+ cl_object safe_cl_funcall(cl_object *error, cl_object fun, cl_object arg)
-+ cl_object safe_cl_apply(cl_object *error, cl_object fun, cl_object args)
-+ cl_object safe_cl_eval(cl_object *error, cl_object form)
-+
++ cdef int fegetexcept()
++ cdef int feenableexcept(int)
++ cdef int fedisableexcept(int)
++ cdef int ecl_feflags
cdef cl_object string_to_object(char * s):
return ecl_read_from_cstring(s)
-@@ -93,9 +100,6 @@ cdef void remove_node(cl_object node):
-
- cdef cl_object list_of_objects
-
--cdef cl_object safe_eval_clobj #our own error catching eval
--cdef cl_object safe_apply_clobj #our own error catching apply
--cdef cl_object safe_funcall_clobj #our own error catching funcall
- cdef cl_object read_from_string_clobj #our own error catching reader
-
- cdef bint ecl_has_booted = 0
@@ -139,7 +143,6 @@ def test_ecl_options():
ECL_OPT_TRAP_SIGINT = 1
ECL_OPT_TRAP_SIGILL = 1
@@ -182,19 +140,13 @@ index 1f05f4a..978e19b 100644
print('ECL_OPT_HEAP_SIZE = {0}'.format(
ecl_get_option(ECL_OPT_HEAP_SIZE)))
print('ECL_OPT_HEAP_SAFETY_AREA = {0}'.format(
-@@ -231,10 +229,8 @@ def init_ecl():
- RuntimeError: ECL is already initialized
- """
- global list_of_objects
-- global safe_eval_clobj
-- global safe_apply_clobj
-- global safe_funcall_clobj
- global read_from_string_clobj
-+ global conditions_to_handle_clobj
+@@ -238,14 +243,12 @@ def init_ecl():
global ecl_has_booted
cdef char *argv[1]
cdef sigaction_t sage_action[32]
-@@ -243,9 +239,6 @@ def init_ecl():
++ cdef int sage_fpes
+ cdef int i
+
if ecl_has_booted:
raise RuntimeError("ECL is already initialized")
@@ -204,19 +156,25 @@ index 1f05f4a..978e19b 100644
#we keep our own GMP memory functions. ECL should not claim them
ecl_set_option(ECL_OPT_SET_GMP_MEMORY_FUNCTIONS,0);
-@@ -259,19 +252,14 @@ def init_ecl():
+@@ -257,6 +263,8 @@ def init_ecl():
+ for i in range(1,32):
+ sigaction(i, NULL, &sage_action[i])
++ sage_fpes = fegetexcept()
++
#initialize ECL
ecl_set_option(ECL_OPT_SIGNAL_HANDLING_THREAD, 0)
-- cl_boot(1, argv)
-+ safe_cl_boot(1, argv)
-
+ cl_boot(1, argv)
+@@ -264,14 +272,12 @@ def init_ecl():
#save signal handler from ECL
sigaction(SIGINT, NULL, &ecl_sigint_handler)
sigaction(SIGBUS, NULL, &ecl_sigbus_handler)
+ sigaction(SIGFPE, NULL, &ecl_sigfpe_handler)
sigaction(SIGSEGV, NULL, &ecl_sigsegv_handler)
++ #save ECL's floating point exception flags
++ ecl_feflags = fegetexcept()
++
- #verify that no SIGCHLD handler was installed
- cdef sigaction_t sig_test
- sigaction(SIGCHLD, NULL, &sig_test)
@@ -226,113 +184,56 @@ index 1f05f4a..978e19b 100644
#and put the Sage signal handlers back
for i in range(1,32):
sigaction(i, &sage_action[i], NULL)
-@@ -293,32 +281,8 @@ def init_ecl():
-
- read_from_string_clobj=cl_eval(string_to_object(b"(symbol-function 'read-from-string)"))
+@@ -276,6 +288,9 @@ def init_ecl():
+ for i in range(1,32):
+ sigaction(i, &sage_action[i], NULL)
-- cl_eval(string_to_object(b"""
-- (defun sage-safe-eval (form)
-- (handler-case
-- (values (eval form))
-- (serious-condition (cnd)
-- (values nil (princ-to-string cnd)))))
-- """))
-- safe_eval_clobj=cl_eval(string_to_object(b"(symbol-function 'sage-safe-eval)"))
--
-- cl_eval(string_to_object(b"""
-- (defun sage-safe-apply (func args)
-- (handler-case
-- (values (apply func args))
-- (serious-condition (cnd)
-- (values nil (princ-to-string cnd)))))
-- """))
++ fedisableexcept(ecl_feflags)
++ feenableexcept(sage_fpes)
++
+ #initialise list of objects and bind to global variable
+ # *SAGE-LIST-OF-OBJECTS* to make it rooted in the reachable tree for the GC
+ list_of_objects=cl_cons(Cnil,cl_cons(Cnil,Cnil))
+@@ -319,7 +334,6 @@ def init_ecl():
+ (values nil (princ-to-string cnd)))))
+ """))
+ safe_funcall_clobj=cl_eval(string_to_object(b"(symbol-function 'sage-safe-funcall)"))
-
-- safe_apply_clobj=cl_eval(string_to_object(b"(symbol-function 'sage-safe-apply)"))
-- cl_eval(string_to_object(b"""
-- (defun sage-safe-funcall (func arg)
-- (handler-case
-- (values (funcall func arg))
-- (serious-condition (cnd)
-- (values nil (princ-to-string cnd)))))
-- """))
-- safe_funcall_clobj=cl_eval(string_to_object(b"(symbol-function 'sage-safe-funcall)"))
-+ conditions_to_handle_clobj=ecl_list1(ecl_make_symbol(b"SERIOUS-CONDITION", b"COMMON-LISP"))
-+ insert_node_after(list_of_objects,conditions_to_handle_clobj)
-
ecl_has_booted = 1
-@@ -339,45 +303,46 @@ cdef cl_object ecl_safe_eval(cl_object form) except NULL:
- ...
- RuntimeError: ECL says: Console interrupt.
- """
-- cdef cl_object s
-+ cdef cl_object ret, error = NULL
-+
- ecl_sig_on()
-- cl_funcall(2,safe_eval_clobj,form)
-+ ret = safe_cl_eval(&error,form)
- ecl_sig_off()
-
-- if ecl_nvalues > 1:
-- s = si_coerce_to_base_string(ecl_values(1))
-+ if error != NULL:
-+ error = si_coerce_to_base_string(error)
- raise RuntimeError("ECL says: {}".format(
-- char_to_str(ecl_base_string_pointer_safe(s))))
-+ char_to_str(ecl_base_string_pointer_safe(error))))
- else:
-- return ecl_values(0)
-+ return ret
-
- cdef cl_object ecl_safe_funcall(cl_object func, cl_object arg) except NULL:
-- cdef cl_object l, s
-- l = cl_cons(func,cl_cons(arg,Cnil));
-+ cdef cl_object ret, error = NULL
-
- ecl_sig_on()
-- cl_apply(2,safe_funcall_clobj,cl_cons(func,cl_cons(arg,Cnil)))
-+ ret = safe_cl_funcall(&error,func,arg)
- ecl_sig_off()
-
-- if ecl_nvalues > 1:
-- s = si_coerce_to_base_string(ecl_values(1))
-+ if error != NULL:
-+ error = si_coerce_to_base_string(error)
- raise RuntimeError("ECL says: {}".format(
-- char_to_str(ecl_base_string_pointer_safe(s))))
-+ char_to_str(ecl_base_string_pointer_safe(error))))
- else:
-- return ecl_values(0)
-+ return ret
-
- cdef cl_object ecl_safe_apply(cl_object func, cl_object args) except NULL:
-- cdef cl_object s
-+ cdef cl_object ret, error = NULL
-+
- ecl_sig_on()
-- cl_funcall(3,safe_apply_clobj,func,args)
-+ ret = safe_cl_apply(&error,func,args)
- ecl_sig_off()
-
-- if ecl_nvalues > 1:
-- s = si_coerce_to_base_string(ecl_values(1))
-+ if error != NULL:
-+ error = si_coerce_to_base_string(error)
- raise RuntimeError("ECL says: {}".format(
-- char_to_str(ecl_base_string_pointer_safe(s))))
-+ char_to_str(ecl_base_string_pointer_safe(error))))
- else:
-- return ecl_values(0)
-+ return ret
-
- cdef cl_object ecl_safe_read_string(char * s) except NULL:
- cdef cl_object o
+ cdef cl_object ecl_safe_eval(cl_object form) except NULL:
diff --git a/src/sage/libs/eclsig.h b/src/sage/libs/eclsig.h
-index f9f2690..e249ccf 100644
+index f9f2690..a7e1f40 100644
--- a/src/sage/libs/eclsig.h
+++ b/src/sage/libs/eclsig.h
-@@ -11,15 +11,18 @@
+@@ -9,24 +9,66 @@
+
+
#include <signal.h>
++
++/* Rummage around to determine how ECL was configured */
++#define ECL_AVOID_FPE_H /* Prevent some local includes */
++#include <ecl/config-internal.h>
++
++#ifdef HAVE_FENV_H
++#include <fenv.h>
++#ifndef FE_ALL_EXCEPT
++#define FE_ALL_EXCEPT FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW | FE_INVALID
++#endif
++#else
++#ifndef FE_ALL_EXCEPT
++#define FE_ALL_EXCEPT 0
++#endif
++#define feclearexcept(flags) do {} while (0)
++#endif
++
++#ifndef HAVE_FEENABLEEXCEPT
++/* These are GNU extensions */
++#define fegetexcept() 0
++#define feenablexcept(flags) do {} while (0)
++#define fdisableexcept(flags) do {} while (0)
++#endif
++
static struct sigaction ecl_sigint_handler;
static struct sigaction ecl_sigbus_handler;
+static struct sigaction ecl_sigfpe_handler;
@@ -341,6 +242,8 @@ index f9f2690..e249ccf 100644
static struct sigaction sage_sigbus_handler;
+static struct sigaction sage_sigfpe_handler;
static struct sigaction sage_sigsegv_handler;
++static int ecl_feflags;
++static int sage_feflags;
static inline void set_ecl_signal_handler(void)
{
@@ -348,66 +251,25 @@ index f9f2690..e249ccf 100644
sigaction(SIGBUS, &ecl_sigbus_handler, &sage_sigbus_handler);
+ sigaction(SIGFPE, &ecl_sigfpe_handler, &sage_sigfpe_handler);
sigaction(SIGSEGV, &ecl_sigsegv_handler, &sage_sigsegv_handler);
++
++ /* first clear pending floating point exceptions, if any */
++ feclearexcept(FE_ALL_EXCEPT);
++
++ /* sage_feflags should be 0; we don't set them otherwise */
++ sage_feflags = fedisableexcept(FE_ALL_EXCEPT);
++ feenableexcept(ecl_feflags);
}
-@@ -27,6 +30,7 @@ static inline void unset_ecl_signal_handler(void)
+ static inline void unset_ecl_signal_handler(void)
{
++ /* clear pending exceptions and restore previous exception mask */
++ feclearexcept(FE_ALL_EXCEPT);
++ ecl_feflags = fedisableexcept(FE_ALL_EXCEPT);
++ feenableexcept(sage_feflags);
++
sigaction(SIGINT, &sage_sigint_handler, NULL);
sigaction(SIGBUS, &sage_sigbus_handler, NULL);
+ sigaction(SIGFPE, &sage_sigfpe_handler, NULL);
sigaction(SIGSEGV, &sage_sigsegv_handler, NULL);
}
-@@ -49,3 +53,52 @@ cl_object ecl_bignum_from_mpz(mpz_t num)
- mpz_set(ecl_mpz_from_bignum(z), num);
- return _ecl_big_register_copy(z);
- }
-+
-+static inline void safe_cl_boot(int argc, char** argv) {
-+ ECL_WITH_LISP_FPE_BEGIN {
-+ cl_boot(argc, argv);
-+ } ECL_WITH_LISP_FPE_END;
-+}
-+
-+/* List of conditions to catch in the following functions. Is
-+ * initialized after cl_boot in init_ecl. */
-+static cl_object conditions_to_handle_clobj = ECL_NIL;
-+
-+static inline cl_object safe_cl_funcall(cl_object *error, cl_object fun, cl_object arg) {
-+ cl_object ret = NULL;
-+ cl_env_ptr the_env = ecl_process_env();
-+ ECL_WITH_LISP_FPE_BEGIN {
-+ ECL_HANDLER_CASE_BEGIN(the_env, conditions_to_handle_clobj) {
-+ ret = cl_funcall(2, fun, arg);
-+ } ECL_HANDLER_CASE(1, condition) {
-+ *error = cl_princ_to_string(condition);
-+ } ECL_HANDLER_CASE_END;
-+ } ECL_WITH_LISP_FPE_END;
-+ return ret;
-+}
-+
-+static inline cl_object safe_cl_apply(cl_object *error, cl_object fun, cl_object args) {
-+ cl_object ret = NULL;
-+ cl_env_ptr the_env = ecl_process_env();
-+ ECL_WITH_LISP_FPE_BEGIN {
-+ ECL_HANDLER_CASE_BEGIN(the_env, conditions_to_handle_clobj) {
-+ ret = cl_apply(2, fun, args);
-+ } ECL_HANDLER_CASE(1, condition) {
-+ *error = cl_princ_to_string(condition);
-+ } ECL_HANDLER_CASE_END;
-+ } ECL_WITH_LISP_FPE_END;
-+ return ret;
-+}
-+
-+static inline cl_object safe_cl_eval(cl_object *error, cl_object form) {
-+ cl_object ret = NULL;
-+ cl_env_ptr the_env = ecl_process_env();
-+ ECL_WITH_LISP_FPE_BEGIN {
-+ ECL_HANDLER_CASE_BEGIN(the_env, conditions_to_handle_clobj) {
-+ ret = cl_eval(form);
-+ } ECL_HANDLER_CASE(1, condition) {
-+ *error = cl_princ_to_string(condition);
-+ } ECL_HANDLER_CASE_END;
-+ } ECL_WITH_LISP_FPE_END;
-+ return ret;
-+}
diff --git a/sagemath-gap-4.11.patch b/sagemath-gap-4.11.patch
index c6113016168e..cba9b189a08b 100644
--- a/sagemath-gap-4.11.patch
+++ b/sagemath-gap-4.11.patch
@@ -192,7 +192,7 @@ diff --git a/src/sage/groups/matrix_gps/finitely_generated.py b/src/sage/groups/
index d356c9cfc1..5f78373a3f 100644
--- a/src/sage/groups/matrix_gps/finitely_generated.py
+++ b/src/sage/groups/matrix_gps/finitely_generated.py
-@@ -549,7 +549,7 @@ class FinitelyGeneratedMatrixGroup_gap(MatrixGroup_gap):
+@@ -550,7 +550,7 @@ class FinitelyGeneratedMatrixGroup_gap(MatrixGroup_gap):
sage: A = MS([[0,0,0,0,1],[0,0,0,1,0],[0,0,1,0,0],[0,1,0,0,0],[1,0,0,0,0]])
sage: G = MatrixGroup([A])
sage: G.as_permutation_group()
@@ -205,7 +205,7 @@ index d356c9cfc1..5f78373a3f 100644
sage: PG = MG.as_permutation_group()
sage: mg = MG.an_element()
sage: PG(mg)
-- (1,2,6,19,35,33)(3,9,26,14,31,23)(4,13,5)(7,22,17)(8,24,12)(10,16,32,27,20,28)(11,30,18)(15,25,36,34,29,21)
+- (1,2,6,19,35,33)(3,9,26,14,31,23)(4,13,5)(7,22,17)(8,24,12)(10,16,32,27,20,28)(11,30,18)(15,25,36,34,29,21)
+ (2,33,32,23,31,55)(3,49,38,44,40,28)(4,17,59,62,58,46)(5,21,47,20,43,8)(6,53,50)(7,37,12,57,14,29)(9,41,56,34,64,10)(11,25,19)(13,61,26,51,22,15)(16,45,36)(18,27,35,48,52,54)(24,63,42)(30,39,60)
"""
# Note that the output of IsomorphismPermGroup() depends on
diff --git a/sagemath-no-dict-sorting.patch b/sagemath-no-dict-sorting.patch
deleted file mode 100644
index 7abeed0154bd..000000000000
--- a/sagemath-no-dict-sorting.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-diff --git a/src/sage/doctest/forker.py b/src/sage/doctest/forker.py
-index c93d1f2..838f1a6 100644
---- a/src/sage/doctest/forker.py
-+++ b/src/sage/doctest/forker.py
-@@ -51,6 +51,7 @@ import tempfile
- from dis import findlinestarts
- from queue import Empty
- import gc
-+import IPython.lib.pretty
-
- import sage.misc.randstate as randstate
- from .util import Timer, RecordingDict, count_noun
-@@ -86,6 +87,32 @@ _OSError_SUBCLASSES = [
- exc is not OSError
- ]
-
-+def _sorted_dict_pprinter_factory(start, end):
-+ """
-+ Modified version of :func:`IPython.lib.pretty._dict_pprinter_factory`
-+ that sorts the keys of dictionaries for printing.
-+
-+ EXAMPLES::
-+
-+ sage: {2: 0, 1: 0} # indirect doctest
-+ {1: 0, 2: 0}
-+ """
-+ def inner(obj, p, cycle):
-+ if cycle:
-+ return p.text('{...}')
-+ step = len(start)
-+ p.begin_group(step, start)
-+ keys = obj.keys()
-+ keys = IPython.lib.pretty._sorted_for_pprint(keys)
-+ for idx, key in p._enumerate(keys):
-+ if idx:
-+ p.text(',')
-+ p.breakable()
-+ p.pretty(key)
-+ p.text(': ')
-+ p.pretty(obj[key])
-+ p.end_group(step, end)
-+ return inner
-
-
- def init_sage():
-@@ -185,11 +212,11 @@ def init_sage():
- # IPython's pretty printer sorts the repr of dicts by their keys by default
- # (or their keys' str() if they are not otherwise orderable). However, it
- # disables this for CPython 3.6+ opting to instead display dicts' "natural"
-- # insertion order, which is preserved in those versions). This makes for
-- # inconsistent results with Python 2 tests that return dicts, so here we
-- # force the Python 2 style dict printing
-- import IPython.lib.pretty
-- IPython.lib.pretty.DICT_IS_ORDERED = False
-+ # insertion order, which is preserved in those versions).
-+ # However, this order is random in some instances.
-+ # Also modifications of code may affect the order.
-+ # So here we fore sorted dict printing.
-+ IPython.lib.pretty.for_type(dict, _sorted_dict_pprinter_factory('{', '}'))
-
- # Switch on extra debugging
- from sage.structure.debug_options import debug
diff --git a/sagemath-pari-2.11.3.patch b/sagemath-pari-2.11.3.patch
deleted file mode 100644
index ff49204f4eb1..000000000000
--- a/sagemath-pari-2.11.3.patch
+++ /dev/null
@@ -1,252 +0,0 @@
-diff --git a/src/sage/lfunctions/dokchitser.py b/src/sage/lfunctions/dokchitser.py
-index 680ac17..1bf8953 100644
---- a/src/sage/lfunctions/dokchitser.py
-+++ b/src/sage/lfunctions/dokchitser.py
-@@ -111,7 +111,7 @@ class Dokchitser(SageObject):
- 0.000000000000000 + 0.305999773834052*z + 0.186547797268162*z^2 - 0.136791463097188*z^3 + O(z^4)
- sage: L.check_functional_equation()
- 6.11218974700000e-18 # 32-bit
-- 6.04442711160669e-18 # 64-bit
-+ 6.11218974738703e-18 # 64-bit
-
- RANK 2 ELLIPTIC CURVE:
-
-@@ -670,7 +670,7 @@ class Dokchitser(SageObject):
- sage: L = Dokchitser(conductor=1, gammaV=[0], weight=1, eps=1, poles=[1], residues=[-1], init='1')
- sage: L.check_functional_equation()
- -1.35525271600000e-20 # 32-bit
-- -2.71050543121376e-20 # 64-bit
-+ -1.35525271560688e-20 # 64-bit
-
- If we choose the sign in functional equation for the
- `\zeta` function incorrectly, the functional equation
-diff --git a/src/sage/lfunctions/pari.py b/src/sage/lfunctions/pari.py
-index c60f944..1daa219 100644
---- a/src/sage/lfunctions/pari.py
-+++ b/src/sage/lfunctions/pari.py
-@@ -423,7 +423,7 @@ class LFunction(SageObject):
- sage: L.taylor_series(1,4)
- 0.000000000000000 + 0.305999773834052*z + 0.186547797268162*z^2 - 0.136791463097188*z^3 + O(z^4)
- sage: L.check_functional_equation()
-- 1.08420217248550e-19
-+ 4.33680868994202e-19
-
- .. RUBRIC:: Rank 2 elliptic curve
-
-diff --git a/src/sage/rings/number_field/number_field.py b/src/sage/rings/number_field/number_field.py
-index 26e219c..9f4681c 100644
---- a/src/sage/rings/number_field/number_field.py
-+++ b/src/sage/rings/number_field/number_field.py
-@@ -3431,18 +3431,18 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- Fractional ideal (2, 1/2*a - 1/2)
- Fractional ideal (2, 1/2*a + 1/2)
- 3
-- Fractional ideal (3, 1/2*a - 1/2)
- Fractional ideal (3, 1/2*a + 1/2)
-+ Fractional ideal (3, 1/2*a - 1/2)
- 4
- Fractional ideal (4, 1/2*a + 3/2)
- Fractional ideal (2)
- Fractional ideal (4, 1/2*a + 5/2)
- 5
- 6
-- Fractional ideal (1/2*a - 1/2)
-- Fractional ideal (6, 1/2*a + 5/2)
- Fractional ideal (6, 1/2*a + 7/2)
- Fractional ideal (1/2*a + 1/2)
-+ Fractional ideal (1/2*a - 1/2)
-+ Fractional ideal (6, 1/2*a + 5/2)
- 7
- 8
- Fractional ideal (1/2*a + 3/2)
-@@ -3450,9 +3450,9 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- Fractional ideal (4, a + 1)
- Fractional ideal (1/2*a - 3/2)
- 9
-- Fractional ideal (9, 1/2*a + 11/2)
-- Fractional ideal (3)
- Fractional ideal (9, 1/2*a + 7/2)
-+ Fractional ideal (3)
-+ Fractional ideal (9, 1/2*a + 11/2)
- 10
- """
- hnf_ideals = self.pari_nf().ideallist(bound)
-@@ -4548,7 +4548,7 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- -1/13*a^2 + 6/13*a + 345/13,
- -1,
- 2/13*a^2 + 1/13*a - 755/13,
-- 1/13*a^2 - 19/13*a - 7/13],
-+ 1/13*a^2 + 20/13*a - 7/13],
- [(Fractional ideal (11, a - 2), 2), (Fractional ideal (19, a + 7), 2)])
-
- Number fields defined by non-monic and non-integral
-@@ -4706,9 +4706,9 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- -1/13*a^2 + 6/13*a + 345/13,
- -1,
- 2/13*a^2 + 1/13*a - 755/13,
-- 1/13*a^2 - 19/13*a - 7/13,
-- -1/13*a^2 + 45/13*a - 97/13,
-- 2/13*a^2 + 40/13*a - 27/13]
-+ 1/13*a^2 + 20/13*a - 7/13,
-+ 1/13*a^2 - 45/13*a + 97/13,
-+ -2/13*a^2 - 40/13*a + 27/13]
-
- Verify that :trac:`16708` is fixed::
-
-@@ -5353,7 +5353,7 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
-
- sage: K.<a> = NumberField(7/9*x^3 + 7/3*x^2 - 56*x + 123)
- sage: K.elements_of_norm(7)
-- [7/225*a^2 - 7/75*a - 42/25]
-+ [28/225*a^2 + 77/75*a - 133/25]
- """
- proof = proof_flag(proof)
- B = self.pari_bnf(proof).bnfisintnorm(n)
-@@ -5456,7 +5456,7 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- sage: pari('setrand(2)')
- sage: L.<b> = K.extension(x^2 - 7)
- sage: f = L.factor(a + 1); f
-- (Fractional ideal (1/2*a*b - a + 1/2)) * (Fractional ideal (-1/2*a*b - a + 1/2))
-+ (Fractional ideal (-1/2*b + 1/2*a + 1)) * (Fractional ideal (-1/2*a*b - a + 1/2))
- sage: f.value() == a+1
- True
-
-@@ -6533,7 +6533,7 @@ class NumberField_generic(WithEqualityById, number_field_base.NumberField):
- sage: [K.uniformizer(P) for P,e in factor(K.ideal(5))]
- [t^2 - t + 1, t + 2, t - 2]
- sage: [K.uniformizer(P) for P,e in factor(K.ideal(7))]
-- [t^2 + 3*t + 1]
-+ [t^2 - 4*t + 1]
- sage: [K.uniformizer(P) for P,e in factor(K.ideal(67))]
- [t + 23, t + 26, t - 32, t - 18]
-
-@@ -7803,11 +7803,11 @@ class NumberField_absolute(NumberField_generic):
- Ring morphism:
- From: Number Field in a1 with defining polynomial x^3 - 7*x - 7
- To: Number Field in a with defining polynomial 7/9*x^3 + 7/3*x^2 - 56*x + 123
-- Defn: a1 |--> 7/225*a^2 - 7/75*a - 42/25,
-+ Defn: a1 |--> 28/225*a^2 + 77/75*a - 133/25,
- Ring morphism:
- From: Number Field in a with defining polynomial 7/9*x^3 + 7/3*x^2 - 56*x + 123
- To: Number Field in a1 with defining polynomial x^3 - 7*x - 7
-- Defn: a |--> -15/7*a1^2 + 9)
-+ Defn: a |--> -60/7*a1^2 + 15*a1 + 39)
- """
- if name is None:
- name = self.variable_names()
-diff --git a/src/sage/rings/number_field/number_field_element.pyx b/src/sage/rings/number_field/number_field_element.pyx
-index 59bab07..079eaaa 100644
---- a/src/sage/rings/number_field/number_field_element.pyx
-+++ b/src/sage/rings/number_field/number_field_element.pyx
-@@ -1733,7 +1733,7 @@ cdef class NumberFieldElement(FieldElement):
- sage: P.<X> = K[]
- sage: L = NumberField(X^2 + a^2 + 2*a + 1, 'b')
- sage: K(17)._rnfisnorm(L)
-- ((a^2 - 2)*b - 4, 1)
-+ ((a^2 - 2)*b + 4, 1)
-
- sage: K.<a> = NumberField(x^3 + x + 1)
- sage: Q.<X> = K[]
-diff --git a/src/sage/rings/number_field/number_field_ideal.py b/src/sage/rings/number_field/number_field_ideal.py
-index 35ee5a6..95ba0f5 100644
---- a/src/sage/rings/number_field/number_field_ideal.py
-+++ b/src/sage/rings/number_field/number_field_ideal.py
-@@ -1823,7 +1823,7 @@ class NumberFieldFractionalIdeal(MultiplicativeGroupElement, NumberFieldIdeal):
-
- sage: F.<a> = NumberField(2*x^3 + x + 1)
- sage: fact = F.factor(2); fact
-- (Fractional ideal (2*a^2 + 1))^2 * (Fractional ideal (-2*a^2))
-+ (Fractional ideal (-2*a^2 - 1))^2 * (Fractional ideal (2*a^2))
- sage: [p[0].norm() for p in fact]
- [2, 2]
- """
-@@ -2414,7 +2414,7 @@ class NumberFieldFractionalIdeal(MultiplicativeGroupElement, NumberFieldIdeal):
- sage: A.is_coprime(B)
- False
- sage: lam = A.idealcoprime(B); lam
-- -1/6*a + 1/6
-+ 1/6*a - 1/6
- sage: (lam*A).is_coprime(B)
- True
-
-diff --git a/src/sage/rings/number_field/unit_group.py b/src/sage/rings/number_field/unit_group.py
-index 6ed0aea..529e23a 100644
---- a/src/sage/rings/number_field/unit_group.py
-+++ b/src/sage/rings/number_field/unit_group.py
-@@ -279,7 +279,7 @@ class UnitGroup(AbelianGroupWithValues_class):
- sage: K.unit_group()
- Unit group with structure C2 x Z x Z of Number Field in a with defining polynomial 7/9*x^3 + 7/3*x^2 - 56*x + 123
- sage: UnitGroup(K, S=tuple(K.primes_above(7)))
-- S-unit group with structure C2 x Z x Z x Z of Number Field in a with defining polynomial 7/9*x^3 + 7/3*x^2 - 56*x + 123 with S = (Fractional ideal (7/225*a^2 - 7/75*a - 42/25),)
-+ S-unit group with structure C2 x Z x Z x Z of Number Field in a with defining polynomial 7/9*x^3 + 7/3*x^2 - 56*x + 123 with S = (Fractional ideal (28/225*a^2 + 77/75*a - 133/25),)
-
- Conversion from unit group to a number field and back
- gives the right results (:trac:`25874`)::
-diff --git a/src/sage/rings/polynomial/polynomial_quotient_ring.py b/src/sage/rings/polynomial/polynomial_quotient_ring.py
-index de62148..e962ad5 100644
---- a/src/sage/rings/polynomial/polynomial_quotient_ring.py
-+++ b/src/sage/rings/polynomial/polynomial_quotient_ring.py
-@@ -1291,9 +1291,9 @@ class PolynomialQuotientRing_generic(CommutativeRing):
- 1/16*a*xbar^3 + (-1/16*a - 1/8)*xbar^2 + 23/16*a*xbar - 23/16*a - 23/8),
- 6),
- ((-5/4*xbar^2 - 115/4,
-- 1/4*a*xbar^2 + 23/4*a,
-- -1/16*xbar^3 - 7/16*xbar^2 - 23/16*xbar - 161/16,
-- 1/16*a*xbar^3 - 1/16*a*xbar^2 + 23/16*a*xbar - 23/16*a),
-+ (1/8*a - 5/8)*xbar^2 + 23/8*a - 115/8,
-+ -1/16*xbar^3 - 17/16*xbar^2 - 23/16*xbar - 391/16,
-+ 1/16*a*xbar^3 + (-1/16*a - 5/8)*xbar^2 + 23/16*a*xbar - 23/16*a - 115/8),
- 2)]
-
- By using the ideal `(a)`, we cut the part of the class group coming from
-@@ -1423,9 +1423,9 @@ class PolynomialQuotientRing_generic(CommutativeRing):
- 1/16*a*xbar^3 + (-1/16*a - 1/8)*xbar^2 + 23/16*a*xbar - 23/16*a - 23/8),
- 6),
- ((-5/4*xbar^2 - 115/4,
-- 1/4*a*xbar^2 + 23/4*a,
-- -1/16*xbar^3 - 7/16*xbar^2 - 23/16*xbar - 161/16,
-- 1/16*a*xbar^3 - 1/16*a*xbar^2 + 23/16*a*xbar - 23/16*a),
-+ (1/8*a - 5/8)*xbar^2 + 23/8*a - 115/8,
-+ -1/16*xbar^3 - 17/16*xbar^2 - 23/16*xbar - 391/16,
-+ 1/16*a*xbar^3 + (-1/16*a - 5/8)*xbar^2 + 23/16*a*xbar - 23/16*a - 115/8),
- 2)]
-
- Note that all the returned values live where we expect them to::
-diff --git a/src/sage/schemes/elliptic_curves/ell_number_field.py b/src/sage/schemes/elliptic_curves/ell_number_field.py
-index 46e7af5..68cf4e3 100644
---- a/src/sage/schemes/elliptic_curves/ell_number_field.py
-+++ b/src/sage/schemes/elliptic_curves/ell_number_field.py
-@@ -301,7 +301,8 @@ class EllipticCurve_number_field(EllipticCurve_field):
- (3,
- 3,
- [(0 : 0 : 1),
-- (-1/2*zeta43_0^2 - 1/2*zeta43_0 + 7 : -3/2*zeta43_0^2 - 5/2*zeta43_0 + 18 : 1)])
-+ (-1/2*zeta43_0^2 - 1/2*zeta43_0 + 7 : -3/2*zeta43_0^2 - 5/2*zeta43_0 + 18 : 1),
-+ (5/8*zeta43_0^2 + 17/8*zeta43_0 - 9/4 : -27/16*zeta43_0^2 - 103/16*zeta43_0 + 39/8 : 1)])
- """
- verbose = int(verbose)
- if known_points is None:
-@@ -809,7 +810,7 @@ class EllipticCurve_number_field(EllipticCurve_field):
- sage: K.<v> = NumberField(x^2 + 161*x - 150)
- sage: E = EllipticCurve([25105/216*v - 3839/36, 634768555/7776*v - 98002625/1296, 634768555/7776*v - 98002625/1296, 0, 0])
- sage: E.global_integral_model()
-- Elliptic Curve defined by y^2 + (2094779518028859*v-1940492905300351)*x*y + (477997268472544193101178234454165304071127500*v-442791377441346852919930773849502871958097500)*y = x^3 + (26519784690047674853185542622500*v-24566525306469707225840460652500)*x^2 over Number Field in v with defining polynomial x^2 + 161*x - 150
-+ Elliptic Curve defined by y^2 + (33872485050625*v-31078224284250)*x*y + (2020602604156076340058146664245468750000*v-1871778534673615560803175189398437500000)*y = x^3 + (6933305282258321342920781250*v-6422644400723486559914062500)*x^2 over Number Field in v with defining polynomial x^2 + 161*x - 150
-
- :trac:`14476`::
-
-@@ -919,10 +920,10 @@ class EllipticCurve_number_field(EllipticCurve_field):
- sage: E1 = E.scale_curve(u^5)
- sage: E1.ainvs()
- (0,
-- 0,
-- 0,
-- 28087920796764302856*a + 88821804456186580548,
-- -77225139016967233228487820912*a - 244207331916752959911655344864)
-+ 0,
-+ 0,
-+ 193309837823322216*a - 611299381639464252,
-+ -3379649566176127326923323632*a + 10687390322316522207588229536)
- sage: E1._scale_by_units().ainvs()
- (0, 0, 0, 4536*a + 14148, -163728*a - 474336)
-
diff --git a/sagemath-sphinx-3.patch b/sagemath-sphinx-3.patch
deleted file mode 100644
index 15e4b2e3ca7a..000000000000
--- a/sagemath-sphinx-3.patch
+++ /dev/null
@@ -1,521 +0,0 @@
-diff --git a/src/doc/en/thematic_tutorials/structures_in_coding_theory.rst b/src/doc/en/thematic_tutorials/structures_in_coding_theory.rst
-index 13f1a83..4726bce 100644
---- a/src/doc/en/thematic_tutorials/structures_in_coding_theory.rst
-+++ b/src/doc/en/thematic_tutorials/structures_in_coding_theory.rst
-@@ -721,8 +721,6 @@ derive from the one that follows.
-
- .. CODE-BLOCK:: python
-
-- :class:`sage.coding.repetition_code.BinaryRepetitionCode <sage.coding.repetition_code.BinaryRepetitionCode>`
-- #the line above creates a link to the class in the html documentation of coding theory library
- from sage.coding.repetition_code import BinaryRepetitionCode
-
- ``encoders_catalog.py`` (continued):
-diff --git a/src/sage/categories/semigroups.py b/src/sage/categories/semigroups.py
-index 3f9939a..a24d8c8 100644
---- a/src/sage/categories/semigroups.py
-+++ b/src/sage/categories/semigroups.py
-@@ -543,7 +543,7 @@ class Semigroups(CategoryWithAxiom):
-
- .. SEEALSO::
-
-- - :wikipedia:`Green's_relations`
-+ - :wikipedia:`Green%27s_relations`
- - :class:`Semigroups.SubcategoryMethods.RTrivial`
- - :class:`Semigroups.SubcategoryMethods.JTrivial`
- - :class:`Semigroups.SubcategoryMethods.HTrivial`
-@@ -588,7 +588,7 @@ class Semigroups(CategoryWithAxiom):
-
- .. SEEALSO::
-
-- - :wikipedia:`Green's_relations`
-+ - :wikipedia:`Green%27s_relations`
- - :class:`Semigroups.SubcategoryMethods.LTrivial`
- - :class:`Semigroups.SubcategoryMethods.JTrivial`
- - :class:`Semigroups.SubcategoryMethods.HTrivial`
-@@ -644,7 +644,7 @@ class Semigroups(CategoryWithAxiom):
-
- .. SEEALSO::
-
-- - :wikipedia:`Green's_relations`
-+ - :wikipedia:`Green%27s_relations`
- - :class:`Semigroups.SubcategoryMethods.LTrivial`
- - :class:`Semigroups.SubcategoryMethods.RTrivial`
- - :class:`Semigroups.SubcategoryMethods.HTrivial`
-@@ -680,7 +680,7 @@ class Semigroups(CategoryWithAxiom):
-
- .. SEEALSO::
-
-- - :wikipedia:`Green's_relations`
-+ - :wikipedia:`Green%27s_relations`
- - :class:`Semigroups.SubcategoryMethods.RTrivial`
- - :class:`Semigroups.SubcategoryMethods.LTrivial`
- - :class:`Semigroups.SubcategoryMethods.JTrivial`
-diff --git a/src/sage/combinat/partition.py b/src/sage/combinat/partition.py
-index 9727c06..36cdd13 100644
---- a/src/sage/combinat/partition.py
-+++ b/src/sage/combinat/partition.py
-@@ -1241,7 +1241,7 @@ class Partition(CombinatorialElement):
-
- REFERENCES:
-
-- - :wikipedia:`Zolotarev's_lemma`
-+ - :wikipedia:`Zolotarev%27s_lemma`
- """
- return (-1)**(self.size()-self.length())
-
-diff --git a/src/sage/combinat/permutation.py b/src/sage/combinat/permutation.py
-index aa0c56b..bcefcbc 100644
---- a/src/sage/combinat/permutation.py
-+++ b/src/sage/combinat/permutation.py
-@@ -412,9 +412,6 @@ class Permutation(CombinatorialElement):
- []
- sage: Permutation( [[], []] )
- []
--
-- .. automethod:: Permutation.left_action_product
-- .. automethod:: Permutation.right_action_product
- """
- @staticmethod
- def __classcall_private__(cls, l, check_input = True):
-diff --git a/src/sage/combinat/posets/posets.py b/src/sage/combinat/posets/posets.py
-index 2795700..00608af 100644
---- a/src/sage/combinat/posets/posets.py
-+++ b/src/sage/combinat/posets/posets.py
-@@ -4221,7 +4221,7 @@ class FinitePoset(UniqueRepresentation, Parent):
- Return the width of the poset (the size of its longest antichain).
-
- It is computed through a matching in a bipartite graph; see
-- :wikipedia:`Dilworth's_theorem` for more information. The width is
-+ :wikipedia:`Dilworth%27s_theorem` for more information. The width is
- also called Dilworth number.
-
- INPUT:
-@@ -4273,7 +4273,7 @@ class FinitePoset(UniqueRepresentation, Parent):
- partitioned into `\alpha` chains, where `\alpha` is the cardinality of
- its largest antichain. This method returns such a partition.
-
-- See :wikipedia:`Dilworth's_theorem`.
-+ See :wikipedia:`Dilworth%27s_theorem`.
-
- ALGORITHM:
-
-diff --git a/src/sage/combinat/root_system/plot.py b/src/sage/combinat/root_system/plot.py
-index 5d1cfe9..f2bc78e 100644
---- a/src/sage/combinat/root_system/plot.py
-+++ b/src/sage/combinat/root_system/plot.py
-@@ -141,7 +141,7 @@ coordinates in the root lattice::
- One can also customize the projection by specifying a function. Here,
- we display all the roots for type `E_8` using the projection from its
- eight dimensional ambient space onto 3D described on
--:wikipedia:`Wikipedia's E8 3D picture <File:E8_3D.png>`::
-+:wikipedia:`Wikipedia%27s E8 3D picture <File:E8_3D.png>`::
-
- sage: M = matrix([[0., -0.556793440452, 0.19694925177, -0.19694925177, 0.0805477263944, -0.385290876171, 0., 0.385290876171],
- ....: [0.180913155536, 0., 0.160212955043, 0.160212955043, 0., 0.0990170516545, 0.766360424875, 0.0990170516545],
-diff --git a/src/sage/docs/conf.py b/src/sage/docs/conf.py
-index a5c8d96..968737e 100644
---- a/src/sage/docs/conf.py
-+++ b/src/sage/docs/conf.py
-@@ -7,6 +7,7 @@ from docutils import nodes
- from docutils.transforms import Transform
- from sphinx.ext.doctest import blankline_re
- from sphinx import highlighting
-+import sphinx.ext.intersphinx as intersphinx
- from IPython.lib.lexers import IPythonConsoleLexer, IPyLexer
-
- # If your extensions are in another directory, add it here.
-@@ -172,13 +173,8 @@ todo_include_todos = True
-
- # Cross-links to other project's online documentation.
- python_version = sys.version_info.major
--intersphinx_mapping = {
-- 'python': ('https://docs.python.org/',
-- os.path.join(SAGE_DOC_SRC, "common",
-- "python{}.inv".format(python_version))),
-- 'pplpy': (PPLPY_DOCS, None)}
-
--def set_intersphinx_mappings(app):
-+def set_intersphinx_mappings(app, config):
- """
- Add precompiled inventory (the objects.inv)
- """
-@@ -189,7 +185,11 @@ def set_intersphinx_mappings(app):
- app.config.intersphinx_mapping = {}
- return
-
-- app.config.intersphinx_mapping = intersphinx_mapping
-+ app.config.intersphinx_mapping = {
-+ 'python': ('https://docs.python.org/',
-+ os.path.join(SAGE_DOC_SRC, "common",
-+ "python{}.inv".format(python_version))),
-+ 'pplpy': (PPLPY_DOCS, None)}
-
- # Add master intersphinx mapping
- dst = os.path.join(invpath, 'objects.inv')
-@@ -204,6 +204,7 @@ def set_intersphinx_mappings(app):
- dst = os.path.join(invpath, directory, 'objects.inv')
- app.config.intersphinx_mapping[src] = dst
-
-+ intersphinx.normalize_intersphinx_mapping(app, config)
-
- # By default document are not master.
- multidocs_is_master = True
-@@ -667,11 +668,11 @@ def call_intersphinx(app, env, node, contnode):
- sage: for line in open(thematic_index).readlines(): # optional - dochtml
- ....: if "padics" in line:
- ....: _ = sys.stdout.write(line)
-- <li><a class="reference external" href="../reference/padics/sage/rings/padics/tutorial.html#sage-rings-padics-tutorial" title="(in Sage... Reference Manual: p-Adics v...)"><span>Introduction to the p-adics</span></a></li>
-+ <li><p><a class="reference external" href="../reference/padics/sage/rings/padics/tutorial.html#sage-rings-padics-tutorial" title="(in Sage... Reference Manual: p-Adics v...)"><span>Introduction to the p-adics</span></a></p></li>
- """
- debug_inf(app, "???? Trying intersphinx for %s" % node['reftarget'])
- builder = app.builder
-- res = sphinx.ext.intersphinx.missing_reference(
-+ res = intersphinx.missing_reference(
- app, env, node, contnode)
- if res:
- # Replace absolute links to $SAGE_DOC by relative links: this
-@@ -854,11 +855,10 @@ def setup(app):
- if app.srcdir.startswith(SAGE_DOC_SRC):
- app.add_config_value('intersphinx_mapping', {}, False)
- app.add_config_value('intersphinx_cache_limit', 5, False)
-+ app.connect('config-inited', set_intersphinx_mappings)
-+ app.connect('builder-inited', intersphinx.load_mappings)
- # We do *not* fully initialize intersphinx since we call it by hand
- # in find_sage_dangling_links.
- # app.connect('missing-reference', missing_reference)
- app.connect('missing-reference', find_sage_dangling_links)
-- import sphinx.ext.intersphinx
-- app.connect('builder-inited', set_intersphinx_mappings)
-- app.connect('builder-inited', sphinx.ext.intersphinx.load_mappings)
- app.connect('builder-inited', nitpick_patch_config)
-diff --git a/src/sage/functions/jacobi.py b/src/sage/functions/jacobi.py
-index 21fbec8..b61892d 100644
---- a/src/sage/functions/jacobi.py
-+++ b/src/sage/functions/jacobi.py
-@@ -125,7 +125,7 @@ equations:
-
- REFERENCES:
-
--- :wikipedia:`Jacobi's_elliptic_functions`
-+- :wikipedia:`Jacobi%27s_elliptic_functions`
-
- - [KS2002]_
-
-diff --git a/src/sage/geometry/riemannian_manifolds/surface3d_generators.py b/src/sage/geometry/riemannian_manifolds/surface3d_generators.py
-index 8bfbba1..078af43 100644
---- a/src/sage/geometry/riemannian_manifolds/surface3d_generators.py
-+++ b/src/sage/geometry/riemannian_manifolds/surface3d_generators.py
-@@ -114,7 +114,7 @@ class SurfaceGenerators():
-
- - ``name`` -- string. Name of the surface.
-
-- For more information, see :wikipedia:`Dini's_surface`.
-+ For more information, see :wikipedia:`Dini%27s_surface`.
-
- EXAMPLES::
-
-diff --git a/src/sage/graphs/base/static_sparse_graph.pyx b/src/sage/graphs/base/static_sparse_graph.pyx
-index 79a32ea..93c534f 100644
---- a/src/sage/graphs/base/static_sparse_graph.pyx
-+++ b/src/sage/graphs/base/static_sparse_graph.pyx
-@@ -682,7 +682,7 @@ def tarjan_strongly_connected_components(G):
- the lowlink of `v`, that whole subtree is a new SCC.
-
- For more information, see the
-- :wikipedia:`Tarjan's_strongly_connected_components_algorithm`.
-+ :wikipedia:`Tarjan%27s_strongly_connected_components_algorithm`.
-
- EXAMPLES::
-
-diff --git a/src/sage/graphs/bipartite_graph.py b/src/sage/graphs/bipartite_graph.py
-index 28cf287..520c4e4 100644
---- a/src/sage/graphs/bipartite_graph.py
-+++ b/src/sage/graphs/bipartite_graph.py
-@@ -1631,7 +1631,7 @@ class BipartiteGraph(Graph):
- among:
-
- - ``"Konig"`` will compute a minimum vertex cover using Konig's
-- algorithm (:wikipedia:`Kőnig's_theorem_(graph_theory)`)
-+ algorithm (:wikipedia:`Kőnig%27s_theorem_(graph_theory)`)
-
- - ``"Cliquer"`` will compute a minimum vertex cover
- using the Cliquer package
-diff --git a/src/sage/graphs/generators/smallgraphs.py b/src/sage/graphs/generators/smallgraphs.py
-index 891aea2..88e6fd9 100644
---- a/src/sage/graphs/generators/smallgraphs.py
-+++ b/src/sage/graphs/generators/smallgraphs.py
-@@ -4325,7 +4325,7 @@ def TietzeGraph():
- Return the Tietze Graph.
-
- For more information on the Tietze Graph, see the
-- :wikipedia:`Tietze's_graph`.
-+ :wikipedia:`Tietze%27s_graph`.
-
- EXAMPLES::
-
-diff --git a/src/sage/graphs/path_enumeration.pyx b/src/sage/graphs/path_enumeration.pyx
-index 5b252b0..1cd0f17 100644
---- a/src/sage/graphs/path_enumeration.pyx
-+++ b/src/sage/graphs/path_enumeration.pyx
-@@ -617,7 +617,7 @@ def yen_k_shortest_simple_paths(self, source, target, weight_function=None,
- and `m` is the number of edges and `k` is the number of shortest paths
- needed to find.
-
-- See [Yen1970]_ and the :wikipedia:`Yen's_algorithm` for more details on the
-+ See [Yen1970]_ and the :wikipedia:`Yen%27s_algorithm` for more details on the
- algorithm.
-
- EXAMPLES::
-diff --git a/src/sage/graphs/spanning_tree.pyx b/src/sage/graphs/spanning_tree.pyx
-index 1572f35..7c8b259 100644
---- a/src/sage/graphs/spanning_tree.pyx
-+++ b/src/sage/graphs/spanning_tree.pyx
-@@ -401,7 +401,7 @@ def filter_kruskal(G, threshold=10000, weight_function=None, bint check=False):
- .. SEEALSO::
-
- - :meth:`sage.graphs.generic_graph.GenericGraph.min_spanning_tree`
-- - :wikipedia:`Kruskal's_algorithm`
-+ - :wikipedia:`Kruskal%27s_algorithm`
- - :func:`kruskal`
- - :func:`filter_kruskal_iterator`
-
-@@ -429,7 +429,7 @@ def filter_kruskal_iterator(G, threshold=10000, weight_function=None, bint check
- .. SEEALSO::
-
- - :meth:`sage.graphs.generic_graph.GenericGraph.min_spanning_tree`
-- - :wikipedia:`Kruskal's_algorithm`
-+ - :wikipedia:`Kruskal%27s_algorithm`
- - :func:`kruskal`
- - :func:`filter_kruskal`
-
-diff --git a/src/sage/groups/matrix_gps/finitely_generated.py b/src/sage/groups/matrix_gps/finitely_generated.py
-index d356c9c..fec4510 100644
---- a/src/sage/groups/matrix_gps/finitely_generated.py
-+++ b/src/sage/groups/matrix_gps/finitely_generated.py
-@@ -48,7 +48,7 @@ AUTHORS:
- - Volker Braun (2013-1) port to new Parent, libGAP.
-
- - Sebastian Oehms (2018-07): Added _permutation_group_element_ (Trac #25706)
--- Sebastian Oehms (2019-01): Revision of :trac:`25706` (:trac:`26903`and :trac:`27143`).
-+- Sebastian Oehms (2019-01): Revision of :trac:`25706` (:trac:`26903` and :trac:`27143`).
- """
-
- ##############################################################################
-diff --git a/src/sage/matroids/linear_matroid.pyx b/src/sage/matroids/linear_matroid.pyx
-index e72f774..bf354d8 100644
---- a/src/sage/matroids/linear_matroid.pyx
-+++ b/src/sage/matroids/linear_matroid.pyx
-@@ -5870,7 +5870,7 @@ cdef class RegularMatroid(LinearMatroid):
- ALGORITHM:
-
- Since the matroid is regular, we use Kirchhoff's Matrix-Tree Theorem.
-- See also :wikipedia:`Kirchhoff's_theorem`.
-+ See also :wikipedia:`Kirchhoff%27s_theorem`.
- """
- if self._bases_count is None:
- R = self._basic_representation()._matrix_()
-diff --git a/src/sage/misc/sagedoc.py b/src/sage/misc/sagedoc.py
-index 61d7a4c..025819d 100644
---- a/src/sage/misc/sagedoc.py
-+++ b/src/sage/misc/sagedoc.py
-@@ -24,7 +24,7 @@ see :trac:`12849`::
- ....: for line in fobj:
- ....: if "#sage.symbolic.expression.Expression.numerical_approx" in line:
- ....: print(line)
-- <code class="descname">numerical_approx</code><span class="sig-paren">(</span><em>prec=None</em>, <em>digits=None</em>, <em>algorithm=None</em><span class="sig-paren">)</span>...
-+ <code class="sig-name descname">numerical_approx</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">prec</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">digits</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">algorithm</span><span class="o">=</span><span class="default_value">None</span></em><span class="sig-paren">)</span>...
-
- Check that sphinx is not imported at Sage start-up::
-
-diff --git a/src/sage/modules/free_module_element.pyx b/src/sage/modules/free_module_element.pyx
-index c0d39da..e60ae43 100644
---- a/src/sage/modules/free_module_element.pyx
-+++ b/src/sage/modules/free_module_element.pyx
-@@ -2698,15 +2698,14 @@ cdef class FreeModuleElement(Vector): # abstract base class
- Return the matrix which describes a cross product
- between ``self`` and some other vector.
-
-- This operation is sometimes written using the `hat operator`_.
-+ This operation is sometimes written using the hat operator:
-+ see :wikipedia:`Hat_operator#Cross_product`.
- It is only defined for vectors of length 3 or 7.
- For a vector `v` the cross product matrix `\hat{v}`
- is a matrix which satisfies `\hat{v} \cdot w = v \times w`
- and also `w \cdot \hat{v} = w \times v` for all vectors `w`.
- The basis vectors are assumed to be orthonormal.
-
-- .. _hat operator: :wikipedia:`Hat_operator#Cross_product`
--
- OUTPUT:
-
- The cross product matrix of this vector.
-diff --git a/src/sage/plot/plot3d/parametric_plot3d.py b/src/sage/plot/plot3d/parametric_plot3d.py
-index da98407..ee1a959 100644
---- a/src/sage/plot/plot3d/parametric_plot3d.py
-+++ b/src/sage/plot/plot3d/parametric_plot3d.py
-@@ -416,7 +416,7 @@ def parametric_plot3d(f, urange, vrange=None, plot_points="automatic",
- f_z = cos(u) / (1 + sqrt(2))
- sphinx_plot(parametric_plot3d([f_x, f_y, f_z], (u,-pi,pi), (v,-pi,pi), frame=False, color="green"))
-
-- Boy's surface (:wikipedia:`Boy's_surface` and https://mathcurve.com/surfaces/boy/boy.shtml)::
-+ Boy's surface (:wikipedia:`Boy%27s_surface` and https://mathcurve.com/surfaces/boy/boy.shtml)::
-
- sage: u, v = var('u,v')
- sage: K = cos(u) / (sqrt(2) - cos(2*u)*sin(3*v))
-diff --git a/src/sage_setup/docbuild/__init__.py b/src/sage_setup/docbuild/__init__.py
-index fd15151..aee7d60 100644
---- a/src/sage_setup/docbuild/__init__.py
-+++ b/src/sage_setup/docbuild/__init__.py
-@@ -816,9 +816,13 @@ class ReferenceSubBuilder(DocBuilder):
-
- env_pickle = os.path.join(self._doctrees_dir(), 'environment.pickle')
- try:
-- env = BuildEnvironment.frompickle(env_pickle, FakeApp(self.dir))
-- logger.debug("Opened Sphinx environment: %s", env_pickle)
-- return env
-+ with open(env_pickle, 'rb') as f:
-+ import pickle
-+ env = pickle.load(f)
-+ env.app = FakeApp(self.dir)
-+ env.config.values = env.app.config.values
-+ logger.debug("Opened Sphinx environment: %s", env_pickle)
-+ return env
- except IOError as err:
- logger.debug("Failed to open Sphinx environment: %s", err)
-
-diff --git a/src/sage_setup/docbuild/ext/multidocs.py b/src/sage_setup/docbuild/ext/multidocs.py
-index ff7b828..37eddae 100644
---- a/src/sage_setup/docbuild/ext/multidocs.py
-+++ b/src/sage_setup/docbuild/ext/multidocs.py
-@@ -50,27 +50,29 @@ def merge_environment(app, env):
- docenv = get_env(app, curdoc)
- if docenv is not None:
- fixpath = lambda path: os.path.join(curdoc, path)
-+ todos = docenv.domaindata['todo'].get('todos', dict())
-+ citations = docenv.domaindata['citation'].get('citations', dict())
-+ indexentries = docenv.domaindata['index'].get('entries', dict())
- logger.info(" %s todos, %s index, %s citations"%(
-- len(docenv.todo_all_todos),
-- len(docenv.indexentries),
-- len(docenv.domaindata["std"]["citations"])
-+ sum(len(t) for t in todos.values()),
-+ len(indexentries),
-+ len(citations)
- ), nonl=1)
-
- # merge titles
- for t in docenv.titles:
- env.titles[fixpath(t)] = docenv.titles[t]
- # merge the todo links
-- for dct in docenv.todo_all_todos:
-- dct['docname'] = fixpath(dct['docname'])
-- env.todo_all_todos += docenv.todo_all_todos
-+ for dct in todos:
-+ env.domaindata['todo']['todos'][fixpath(dct)] = todos[dct]
- # merge the html index links
- newindex = {}
-- for ind in docenv.indexentries:
-+ for ind in indexentries:
- if ind.startswith('sage/'):
-- newindex[fixpath(ind)] = docenv.indexentries[ind]
-+ newindex[fixpath(ind)] = indexentries[ind]
- else:
-- newindex[ind] = docenv.indexentries[ind]
-- env.indexentries.update(newindex)
-+ newindex[ind] = indexentries[ind]
-+ env.domaindata['index']['entries'].update(newindex)
- # merge the all_docs links, needed by the js index
- newalldoc = {}
- for ind in docenv.all_docs:
-@@ -84,24 +86,23 @@ def merge_environment(app, env):
- env.metadata[ind] = md
- # merge the citations
- newcite = {}
-- citations = docenv.domaindata["std"]["citations"]
-- for ind, (path, tag, lineno) in docenv.domaindata["std"]["citations"].items():
-+ for ind, (path, tag, lineno) in citations.items():
- # TODO: Warn on conflicts
- newcite[ind] = (fixpath(path), tag, lineno)
-- env.domaindata["std"]["citations"].update(newcite)
-+ env.domaindata['citation']['citations'].update(newcite)
- # merge the py:module indexes
- newmodules = {}
-- for ind,(modpath,v1,v2,v3) in (
-+ for ind,(modpath,v1,v2,v3,v4) in (
- docenv.domaindata['py']['modules'].items()):
-- newmodules[ind] = (fixpath(modpath),v1,v2,v3)
-+ newmodules[ind] = (fixpath(modpath),v1,v2,v3,v4)
- env.domaindata['py']['modules'].update(newmodules)
- logger.info(", %s modules"%(len(newmodules)))
- logger.info('... done (%s todos, %s index, %s citations, %s modules)'%(
-- len(env.todo_all_todos),
-- len(env.indexentries),
-- len(env.domaindata["std"]["citations"]),
-+ sum(len(t) for t in env.domaindata['todo']['todos'].values()),
-+ len(env.domaindata['index']['entries']),
-+ len(env.domaindata['citation']['citations']),
- len(env.domaindata['py']['modules'])))
-- write_citations(app, env.domaindata["std"]["citations"])
-+ write_citations(app, env.domaindata['citation']['citations'])
-
-
- def get_env(app, curdoc):
-@@ -251,7 +252,7 @@ def fetch_citation(app, env):
- with open(filename, 'rb') as f:
- cache = pickle.load(f)
- logger.info("done (%s citations)."%len(cache))
-- cite = env.domaindata["std"]["citations"]
-+ cite = env.domaindata['citation'].get('citations', dict())
- for ind, (path, tag, lineno) in cache.items():
- if ind not in cite: # don't override local citation
- cite[ind] = (os.path.join("..", path), tag, lineno)
-diff --git a/src/sage_setup/docbuild/ext/sage_autodoc.py b/src/sage_setup/docbuild/ext/sage_autodoc.py
-index 727ce30..032365d 100644
---- a/src/sage_setup/docbuild/ext/sage_autodoc.py
-+++ b/src/sage_setup/docbuild/ext/sage_autodoc.py
-@@ -35,14 +35,15 @@ import sys
- from docutils.statemachine import ViewList
-
- import sphinx
--from sphinx.ext.autodoc.importer import mock, import_object, get_object_members
-+from sphinx.ext.autodoc import mock
-+from sphinx.ext.autodoc.importer import import_object, get_object_members, get_module_members
- from sphinx.locale import _, __
- from sphinx.pycode import ModuleAnalyzer
- from sphinx.errors import PycodeError
- from sphinx.util import logging
- from sphinx.util import rpartition, force_decode
- from sphinx.util.docstrings import prepare_docstring
--from sphinx.util.inspect import isdescriptor, safe_getmembers, \
-+from sphinx.util.inspect import isdescriptor, \
- safe_getattr, object_description, is_builtin_class_method, \
- isenumattribute, isclassmethod, isstaticmethod, getdoc
-
-@@ -536,7 +537,7 @@ class Documenter(object):
-
- # add content from docstrings
- if not no_docstring:
-- encoding = self.analyzer and self.analyzer.encoding
-+ encoding = self.analyzer and self.analyzer._encoding
- docstrings = self.get_doc(encoding)
- if not docstrings:
- # append at least a dummy docstring, so that the event
-@@ -882,7 +883,7 @@ class ModuleDocumenter(Documenter):
- if not hasattr(self.object, '__all__'):
- # for implicit module members, check __module__ to avoid
- # documenting imported objects
-- return True, safe_getmembers(self.object)
-+ return True, get_module_members(self.object)
- else:
- memberlist = self.object.__all__
- # Sometimes __all__ is broken...
-@@ -893,7 +894,7 @@ class ModuleDocumenter(Documenter):
- '(in module %s) -- ignoring __all__' %
- (memberlist, self.fullname))
- # fall back to all members
-- return True, safe_getmembers(self.object)
-+ return True, get_module_members(self.object)
- else:
- memberlist = self.options.members or []
- ret = []
diff --git a/sagemath-sympy-1.6.patch b/sagemath-sympy-1.6.patch
deleted file mode 100644
index c114f4714d65..000000000000
--- a/sagemath-sympy-1.6.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-diff --git a/build/pkgs/sympy/checksums.ini b/build/pkgs/sympy/checksums.ini
-index 1b98ad8879..e5b80927ab 100644
---- a/build/pkgs/sympy/checksums.ini
-+++ b/build/pkgs/sympy/checksums.ini
-@@ -1,4 +1,5 @@
- tarball=sympy-VERSION.tar.gz
--sha1=be2e740860f7900f0ee2a8102d2943fded44125c
--md5=fa9ad424535075312df022964ede21bc
--cksum=3298250000
-+sha1=067078df2d0401f3c4b49ee2e50a4105f92c5272
-+md5=dbb7b21d2972c41f37d48f744b6189a3
-+cksum=575244204
-+upstream_url=https://github.com/sympy/sympy/releases/download/sympy-VERSION/sympy-VERSION.tar.gz
-diff --git a/build/pkgs/sympy/package-version.txt b/build/pkgs/sympy/package-version.txt
-index c239c60cba..810ee4e91e 100644
---- a/build/pkgs/sympy/package-version.txt
-+++ b/build/pkgs/sympy/package-version.txt
-@@ -1 +1 @@
--1.5
-+1.6
-diff --git a/src/sage/calculus/test_sympy.py b/src/sage/calculus/test_sympy.py
-index 9fb9358cb2..86f9366704 100644
---- a/src/sage/calculus/test_sympy.py
-+++ b/src/sage/calculus/test_sympy.py
-@@ -109,7 +109,7 @@ And here are some actual tests of sympy::
-
- sage: e = (1/cos(x)^3)._sympy_(); e
- cos(x)**(-3)
-- sage: f = e.series(x, 0, 10); f
-+ sage: f = e.series(x, 0, int(10)); f
- 1 + 3*x**2/2 + 11*x**4/8 + 241*x**6/240 + 8651*x**8/13440 + O(x**10)
-
- And the pretty-printer. Since unicode characters are not working on
-diff --git a/src/sage/manifolds/calculus_method.py b/src/sage/manifolds/calculus_method.py
-index 7042afe77a..a658551ee9 100644
---- a/src/sage/manifolds/calculus_method.py
-+++ b/src/sage/manifolds/calculus_method.py
-@@ -65,7 +65,7 @@ def _SR_to_Sympy(expression):
-
- """
- # Nothing to do if expression is already a SymPy object:
-- if type(expression) in sympy.core.all_classes:
-+ if type(expression) in sympy.core.core.all_classes:
- return expression
- return SR(expression)._sympy_()
-
-diff --git a/src/sage/symbolic/relation.py b/src/sage/symbolic/relation.py
-index 028f628797..d252434d52 100644
---- a/src/sage/symbolic/relation.py
-+++ b/src/sage/symbolic/relation.py
-@@ -913,7 +913,8 @@ def solve(f, *args, **kwds):
- print them::
-
- sage: solve(sinh(x) - 2*cosh(x),x,algorithm='sympy')
-- ConditionSet(x, Eq((-exp(2*x) - 3)*exp(-x)/2, 0), Reals)
-+ [ImageSet(Lambda(_n, I*(2*_n*pi + pi/2) + log(sqrt(3))), Integers),
-+ ImageSet(Lambda(_n, I*(2*_n*pi - pi/2) + log(sqrt(3))), Integers)]
- sage: solve(2*sin(x) - 2*sin(2*x), x,algorithm='sympy')
- [ImageSet(Lambda(_n, 2*_n*pi), Integers),
- ImageSet(Lambda(_n, 2*_n*pi + pi), Integers),