From b54d843eac905993eba2314a89a2d7f155445eaa Mon Sep 17 00:00:00 2001 From: Tim Ruffing Date: Mon, 31 Jan 2022 15:17:46 +0100 Subject: [PATCH] sage: Fix printing of errors Python 3 often returns iterable map objects where Python 2 returned list. We can just them down to lists explicitly. Overlooked in 13c88efed0005eb6745a222963ee74564054eafb. --- sage/group_prover.sage | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sage/group_prover.sage b/sage/group_prover.sage index 999da52..a35d17b 100644 --- a/sage/group_prover.sage +++ b/sage/group_prover.sage @@ -254,7 +254,7 @@ def prove_zero(R, exprs, assume): """Check whether all of the passed expressions are provably zero, given assumptions""" r, e = prove_nonzero(R, dict(map(lambda x: (fastfrac(R, x.bot, 1), exprs[x]), exprs)), assume) if not r: - return (False, map(lambda x: "Possibly zero denominator: %s" % x, e)) + return (False, list(map(lambda x: "Possibly zero denominator: %s" % x, e))) zero = R.ideal(list(map(numerator, assume.zero))) nonzero = prod(x for x in assume.nonzero) expl = []