Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix invalid use of sig_on() in sage.matrix.matrix_sparse.Matrix_sparse._multiply_classical #27477

Closed
jdemeyer opened this issue Mar 13, 2019 · 8 comments

Comments

@jdemeyer
Copy link

sage -t --long src/sage/rings/number_field/number_field.py
**********************************************************************
File "src/sage/rings/number_field/number_field.py", line 1288, in sage.rings.number_field.number_field.NumberField_generic
Failed example:
    for chi in G:
        D = ModularSymbols(chi, 2, -1).cuspidal_subspace().new_subspace().decomposition()
        for f in D:
            elt = f.q_eigenform(10, 'alpha')[3]
            assert elt.is_integral()
Exception raised:
    Traceback (most recent call last):
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 671, in _run
        self.compile_and_execute(example, compiler, test.globs)
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 1095, in compile_and_execute
        exec(compiled, globs)
      File "<doctest sage.rings.number_field.number_field.NumberField_generic[47]>", line 4, in <module>
        elt = f.q_eigenform(Integer(10), 'alpha')[Integer(3)]
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/modular/modsym/space.py", line 1263, in q_eigenform
        ext = [self.eigenvalue(n, names) for n in range(f.prec(),prec)]
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/modular/hecke/module.py", line 1304, in eigenvalue
        Tn_e = self._eigen_nonzero_element(n)
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/modular/hecke/module.py", line 635, in _eigen_nonzero_element
        return A._hecke_image_of_ith_basis_vector(n, i)
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/modular/hecke/module.py", line 650, in _hecke_image_of_ith_basis_vector
        return T.apply_sparse(self.gen(i))
      File "/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/modular/modsym/hecke_operator.py", line 72, in apply_sparse
        return M(v.parent()((W * R).row(0)))
      File "sage/structure/element.pyx", line 3681, in sage.structure.element.Matrix.__mul__ (build/cythonized/sage/structure/element.c:22564)
        return coercion_model.bin_op(left, right, mul)
      File "sage/structure/coerce.pyx", line 1158, in sage.structure.coerce.CoercionModel.bin_op (build/cythonized/sage/structure/coerce.c:9985)
        return (<Action>action)._act_(x, y)
      File "sage/matrix/action.pyx", line 260, in sage.matrix.action.MatrixMatrixAction._act_ (build/cythonized/sage/matrix/action.c:4606)
        prod = A._matrix_times_matrix_(B)
      File "sage/matrix/matrix0.pyx", line 5213, in sage.matrix.matrix0.Matrix._matrix_times_matrix_ (build/cythonized/sage/matrix/matrix0.c:35087)
        return self._multiply_classical(right)
      File "sage/matrix/matrix_sparse.pyx", line 193, in sage.matrix.matrix_sparse.Matrix_sparse._multiply_classical (build/cythonized/sage/matrix/matrix_sparse.c:3861)
        sig_on()
    SystemError: calling remove_from_pari_stack() inside sig_on()
**********************************************************************

Component: cython

Author: Jeroen Demeyer

Branch/Commit: c9b0cc9

Reviewer: Frédéric Chapoton

Issue created by migration from https://trac.sagemath.org/ticket/27477

@jdemeyer jdemeyer added this to the sage-8.7 milestone Mar 13, 2019
@jdemeyer
Copy link
Author

@jdemeyer
Copy link
Author

New commits:

c9b0cc9Fix invalid uses of sig_on() in sage.matrix.matrix_sparse.Matrix_sparse

@jdemeyer
Copy link
Author

Commit: c9b0cc9

@jdemeyer
Copy link
Author

Author: Jeroen Demeyer

@fchapoton
Copy link
Contributor

Reviewer: Frédéric Chapoton

@fchapoton
Copy link
Contributor

comment:3

ok, thx

@embray
Copy link
Contributor

embray commented Mar 25, 2019

comment:4

Ticket retargeted after milestone closed (if you don't believe this ticket is appropriate for the Sage 8.8 release please retarget manually)

@embray embray modified the milestones: sage-8.7, sage-8.8 Mar 25, 2019
@vbraun
Copy link
Member

vbraun commented Mar 25, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants