Skip to content

Commit a67b88e

Browse files
committed
sage math import break up: adding missing import of is_prime.
1 parent 40a7356 commit a67b88e

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

python/sage_helper.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,11 @@ def sage_method(function):
3737
from sage.all import VectorSpace, ChainComplex
3838
from sage.all import ComplexBallField, exp, sin, block_matrix, prime_range, det
3939
from sage.all import LaurentPolynomialRing, AbelianGroup, GroupAlgebra
40+
from sage.all import is_prime
4041
except ImportError:
4142
# Modularized Sage library
4243
from sage.algebras.group_algebra import GroupAlgebra
43-
from sage.arith.misc import gcd, xgcd
44+
from sage.arith.misc import gcd, xgcd, is_prime
4445
from sage.combinat.subset import powerset
4546
from sage.functions.hyperbolic import arccosh
4647
from sage.functions.log import exp

python/snap/slice_obs_HKL.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545

4646
from ..sage_helper import _within_sage, sage_method
4747
if _within_sage:
48-
from ..sage_helper import ZZ, PolynomialRing, vector, matrix, identity_matrix, MatrixSpace, block_matrix, prime_range
48+
from ..sage_helper import ZZ, PolynomialRing, vector, matrix, identity_matrix, MatrixSpace, block_matrix, prime_range, is_prime
4949
from ..sage_helper import LaurentPolynomialRing, GF, CyclotomicField, ChainComplex
5050

5151
from .nsagetools import (MapToFreeAbelianization, compute_torsion,

0 commit comments

Comments
 (0)