#6391: libGAP!  -- create a Cython library interface to gap
---------------------------+------------------------------------------------
   Reporter:  was          |       Owner:  was     
       Type:  enhancement  |      Status:  new     
   Priority:  major        |   Milestone:  sage-4.4
  Component:  interfaces   |    Keywords:          
     Author:               |    Upstream:  N/A     
   Reviewer:               |      Merged:          
Work_issues:               |  
---------------------------+------------------------------------------------

Comment(by davidm):

 I get an error when importing libgap on sage 4.3.5 on OSX 10.6.3:


 {{{
 sage: import sage.libs.gap.gap
 ---------------------------------------------------------------------------
 AttributeError                            Traceback (most recent call
 last)

 /Users/ayeq/sage-devel/<ipython console> in <module>()

 /Users/ayeq/sage-devel/gap.pyx in init sage.libs.gap.gap
 (sage/libs/gap/gap.c:6286)()

 /Users/ayeq/sage-devel/local/lib/python2.6/site-
 packages/sage/misc/cachefunc.pyc in __init__(self, f, classmethod)
      54
      55         """
 ---> 56         self._common_init(f,
 ArgumentFixer(f,classmethod=classmethod))
      57         self.cache = {}
      58

 /Users/ayeq/sage-devel/local/lib/python2.6/site-
 packages/sage/misc/function_mangling.pyc in __init__(self, f, classmethod)
     107         """
     108
 --> 109         defaults = f.func_defaults
     110         if defaults is None:
     111             defaults = []

 AttributeError: 'builtin_function_or_method' object has no attribute
 'func_defaults'
 }}}

 The cached_function decorator works at the interpreter level so I really
 do not see what is happening. When the line is removed  the import works
 fine and from what I understand about cache_function this should be okay.

 {{{
 --- a/sage/libs/gap/gap.pyx     Sat Jun 27 05:49:14 2009 +0200
 +++ b/sage/libs/gap/gap.pyx     Sat Apr 10 16:30:27 2010 -0700
 @@ -71,8 +71,8 @@

  from sage.structure.element cimport ModuleElement, RingElement

 -from sage.misc.cachefunc import cached_function
 -...@cached_function
 +#from sage.misc.cachefunc import cached_function
 +...@cached_function
  def gap_root():
      """
      Find the location of the GAP root install which is stored in the gap
 }}}

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