#11521: Memleak when resolving the action of Integers on an Elliptic Curve
------------------------+---------------------------------------------------
   Reporter:  jpflori   |          Owner:  robertwb  
       Type:  defect    |         Status:  needs_info
   Priority:  major     |      Milestone:  sage-4.8  
  Component:  coercion  |       Keywords:            
Work_issues:            |       Upstream:  N/A       
   Reviewer:            |         Author:            
     Merged:            |   Dependencies:            
------------------------+---------------------------------------------------

Comment(by SimonKing):

 FWIW:

 With the latest patch, the tests in polynomial_singular_interface and in
 multi_polynomial_ring pass.

 There remain the following problems:

 {{{
 sage -t  "devel/sage-main/sage/structure/parent.pyx"
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/parent.pyx", line 1410:
     sage: n = 5; Hom(n,7)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_33[4]>", line 1, in <module>
         n = Integer(5); Hom(n,Integer(7))###line 1410:
     sage: n = 5; Hom(n,7)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.integer.Integer' object
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/parent.pyx", line 1412:
     sage: z=(2/3); Hom(z,8/1)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_33[5]>", line 1, in <module>
         z=(Integer(2)/Integer(3)); Hom(z,Integer(8)/Integer(1))###line
 1412:
     sage: z=(2/3); Hom(z,8/1)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.rational.Rational' object
 **********************************************************************
 1 items had failures:
    2 of   8 in __main__.example_33
 ***Test Failed*** 2 failures.
 For whitespace errors, see the file /home/simon/.sage//tmp/parent_2986.py
          [11.6 s]
 }}}
 and
 {{{
 sage -t  "devel/sage-main/sage/structure/category_object.pyx"
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/category_object.pyx", line 590:
     sage: n = 5; Hom(n,7)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_17[4]>", line 1, in <module>
         n = Integer(5); Hom(n,Integer(7))###line 590:
     sage: n = 5; Hom(n,7)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.integer.Integer' object
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/category_object.pyx", line 592:
     sage: z=(2/3); Hom(z,8/1)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_17[5]>", line 1, in <module>
         z=(Integer(2)/Integer(3)); Hom(z,Integer(8)/Integer(1))###line
 592:
     sage: z=(2/3); Hom(z,8/1)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.rational.Rational' object
 **********************************************************************
 1 items had failures:
    2 of   8 in __main__.example_17
 ***Test Failed*** 2 failures.
 For whitespace errors, see the file
 /home/simon/.sage//tmp/category_object_3050.py
          [2.7 s]
 }}}
 and
 {{{
 sage -t  "devel/sage-main/sage/structure/parent_base.pyx"
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/parent_base.pyx", line 108:
     sage: n = 5; Hom(n,7)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_3[4]>", line 1, in <module>
         n = Integer(5); Hom(n,Integer(7))###line 108:
     sage: n = 5; Hom(n,7)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.integer.Integer' object
 **********************************************************************
 File "/home/simon/SAGE/sage-4.8.alpha3/devel/sage-
 main/sage/structure/parent_base.pyx", line 110:
     sage: z=(2/3); Hom(z,8/1)
 Exception raised:
     Traceback (most recent call last):
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1231, in run_one_test
         self.run_one_example(test, example, filename, compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/sagedoctest.py",
 line 38, in run_one_example
         OrigDocTestRunner.run_one_example(self, test, example, filename,
 compileflags)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/bin/ncadoctest.py",
 line 1172, in run_one_example
         compileflags, 1) in test.globs
       File "<doctest __main__.example_3[5]>", line 1, in <module>
         z=(Integer(2)/Integer(3)); Hom(z,Integer(8)/Integer(1))###line
 110:
     sage: z=(2/3); Hom(z,8/1)
       File "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python/site-
 packages/sage/categories/homset.py", line 159, in Hom
         cache2 = _cache[X]
       File
 "/home/simon/SAGE/sage-4.8.alpha3/local/lib/python2.6/weakref.py", line
 243, in __getitem__
         return self.data[ref(key)]
     TypeError: cannot create weak reference to
 'sage.rings.rational.Rational' object
 **********************************************************************
 1 items had failures:
    2 of   8 in __main__.example_3
 ***Test Failed*** 2 failures.
 For whitespace errors, see the file
 /home/simon/.sage//tmp/parent_base_3078.py
          [2.6 s]
 }}}

 So, essentially this is just a single test that comes in two versions and
 is repeated three times - and I would actually say that ''not'' raising an
 error was a bug.

 It seems that `Hom(1/2,2/3)` and similar nonsense is not used in Sage.
 Hence, I think these tests should be removed. I'll ask sage-devel.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11521#comment:39>
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.

Reply via email to