#8800: Doctest coverage of categories
--------------------------+-------------------------------------------------
Reporter: SimonKing | Owner: Simon King
Type: defect | Status: new
Priority: major | Milestone: sage-4.4.2
Component: categories | Keywords: categories doctests
Author: Simon King | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
--------------------------+-------------------------------------------------
Comment(by SimonKing):
I am now almost finished with the doc tests for pushout.py.
The soon-to-be-submitted patch is already quite big, and comprises various
bug fixes. I suggest that this ticket will mainly be about pushout.py, and
the other files will be done on a separate ticket.
Here are three more bugs. Number one:
{{{
sage: sage: P.<x> = QQ[]
sage: P.<x> = QQ[]
sage: Q1 = P.quo([(x^2+1)^2*(x^2-3)])
sage: Q2 = P.quo([(x^2+1)^2*(x^5+3)])
sage: from sage.categories.pushout import pushout
sage: pushout(Q1,Q2)
---------------------------------------------------------------------------
CoercionException Traceback (most recent call
last)
/home/king/SAGE/work/invarianten/<ipython console> in <module>()
/home/king/SAGE/sage-4.3.1/local/lib/python2.6/site-
packages/sage/categories/pushout.pyc in pushout(R, S)
1037
1038 else:
-> 1039 raise CoercionException, "No common base"
1040
1041 # Rc is a list of functors from Z to R and Sc is a list of
functors from Z to S
CoercionException: No common base
}}}
This I can fix. The problem is that the quotient rings have no proper
``construction()`` method.
Number 2, continuing the above example:
{{{
sage: Q = P.quo([(x^2+1)^2])
sage: Q.has_coerce_map_from(Q1)
False
sage: Q.has_coerce_map_from(Q2)
False
}}}
This is wrong since the modulus of Q divides the modulus of Q1 and Q2.
Actually Q is supposed to be the pushout of Q1 and Q2.
Number three:
{{{
sage: Q(Q1.gen())
ERROR: An unexpected error occurred while tokenizing input
The following traceback may be corrupted or invalid
The error message is: ('EOF in multi-line statement', (932, 0))
...
TypeError: Unable to coerce xbar (<class
'sage.rings.polynomial.polynomial_quotient_ring_element.PolynomialQuotientRingElement'>)
to Rational
}}}
But I guess these last two errors should be on a different ticket.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/8800#comment:25>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.