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

Polynomial generic power trunk broken #32075

Open
kliem opened this issue Jun 28, 2021 · 1 comment
Open

Polynomial generic power trunk broken #32075

kliem opened this issue Jun 28, 2021 · 1 comment

Comments

@kliem
Copy link
Contributor

kliem commented Jun 28, 2021

From #29979:

Doctesting 1 file.
sage -t --long --random-seed=151058820726654196682836430928254760259 src/sage/rings/polynomial/polynomial_element.pyx
**********************************************************************
File "src/sage/rings/polynomial/polynomial_element.pyx", line 11581, in sage.rings.polynomial.polynomial_element.generic_power_trunc
Failed example:
    for S in [ZZ, GF(3)]:
        R = PolynomialRing(S, 'x')
        for _ in range(100):
            p = R.random_element()
            n = ZZ.random_element(0, 100)
            prec = ZZ.random_element(0, 100)
            assert p.power_trunc(n, prec) == generic_power_trunc(p, n, prec), "p = {} n = {} prec = {}".format(p, n, prec)
Exception raised:
    Traceback (most recent call last):
      File "/srv/public/kliem/sage/local/lib/python3.7/site-packages/sage/doctest/forker.py", line 714, in _run
        self.compile_and_execute(example, compiler, test.globs)
      File "/srv/public/kliem/sage/local/lib/python3.7/site-packages/sage/doctest/forker.py", line 1133, in compile_and_execute
        exec(compiled, globs)
      File "<doctest sage.rings.polynomial.polynomial_element.generic_power_trunc[1]>", line 7, in <module>
        assert p.power_trunc(n, prec) == generic_power_trunc(p, n, prec), "p = {} n = {} prec = {}".format(p, n, prec)
    AssertionError: p = 0 n = 0 prec = 93
**********************************************************************
1 item had failures:
   1 of   3 in sage.rings.polynomial.polynomial_element.generic_power_trunc
    [2631 tests, 1 failure, 8.27 s]
----------------------------------------------------------------------
sage -t --long --random-seed=151058820726654196682836430928254760259 src/sage/rings/polynomial/polynomial_element.pyx  # 1 doctest failed

In #29979, a doctest was marked not tested because of this.

Component: algebra

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

@kliem kliem added this to the sage-9.4 milestone Jun 28, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.4, sage-9.5 Aug 22, 2021
@mwageringel

This comment has been minimized.

@mkoeppe mkoeppe modified the milestones: sage-9.5, sage-9.6 Dec 18, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.6, sage-9.7 May 3, 2022
@mkoeppe mkoeppe modified the milestones: sage-9.7, sage-9.8 Sep 19, 2022
@mkoeppe mkoeppe removed this from the sage-9.8 milestone Jan 29, 2023
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

3 participants