https://trac.sagemath.org/ticket/25379

Purportetly fixes this randomly occuring bug:


sage -t --long src/sage/coding/code_constructions.py
**********************************************************************
File "src/sage/coding/code_constructions.py", line 624, in 
sage.coding.code_constructions.QuadraticResidueCodeOddPair
Failed example:
    codes.QuadraticResidueCodeOddPair(17, GF(13))
Exception raised:
    Traceback (most recent call last):
      File 
"/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/doctest/forker.py",
 
line 562, 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 972, in compile_and_execute
        exec(compiled, globs)
      File "<doctest 
sage.coding.code_constructions.QuadraticResidueCodeOddPair[0]>", line 1, in 
<module>
        codes.QuadraticResidueCodeOddPair(Integer(17), GF(Integer(13)))
      File 
"/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/coding/code_constructions.py",
 
line 666, in QuadraticResidueCodeOddPair
        return DuadicCodeOddPair(F,Q,N)
      File 
"/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/coding/code_constructions.py",
 
line 425, in DuadicCodeOddPair
        gg1 = P2(coeffs1)
      File "sage/structure/parent.pyx", line 920, in 
sage.structure.parent.Parent.__call__ 
(build/cythonized/sage/structure/parent.c:9734)
        return mor._call_(x)
      File "sage/structure/coerce_maps.pyx", line 145, in 
sage.structure.coerce_maps.DefaultConvertMap_unique._call_ 
(build/cythonized/sage/structure/coerce_maps.c:4555)
        raise
      File "sage/structure/coerce_maps.pyx", line 140, in 
sage.structure.coerce_maps.DefaultConvertMap_unique._call_ 
(build/cythonized/sage/structure/coerce_maps.c:4423)
        return C._element_constructor(x)
      File 
"/home/vdelecro/sage_patchbot/local/lib/python2.7/site-packages/sage/rings/polynomial/polynomial_ring.py",
 
line 404, in _element_constructor_
        return C(self, x, check=check, is_gen=False, construct=construct)
      File "sage/rings/polynomial/polynomial_zmod_flint.pyx", line 100, in 
sage.rings.polynomial.polynomial_zmod_flint.Polynomial_zmod_flint.__init__ 
(build/cythonized/sage/rings/polynomial/polynomial_zmod_flint.cpp:14356)
        lst = [k(i) for i in x]
      File "sage/structure/parent.pyx", line 920, in 
sage.structure.parent.Parent.__call__ 
(build/cythonized/sage/structure/parent.c:9734)
        return mor._call_(x)
      File "sage/rings/finite_rings/hom_prime_finite_field.pyx", line 46, 
in 
sage.rings.finite_rings.hom_prime_finite_field.SectionFiniteFieldHomomorphism_prime._call_
 
(build/cythonized/sage/rings/finite_rings/hom_prime_finite_field.c:3457)
        raise ValueError("%s is not in the image of %s" % (x, 
self._inverse))
    ValueError: 10*z^3 + 9*z^2 + z is not in the image of (map internal to 
coercion system -- copy before use)
    Ring morphism:
      From: Finite Field of size 13
      To:   Finite Field in z of size 13^4
**********************************************************************
1 item had failures:
   1 of  13 in sage.coding.code_constructions.QuadraticResidueCodeOddPair
    [146 tests, 1 failure, 2.83 s]
----------------------------------------------------------------------
sage -t --long src/sage/coding/code_constructions.py  # 1 doctest failed
----------------------------------------------------------------------

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to