#16624: upgrade sympy to version 0.7.5
-------------------------------------+-------------------------------------
       Reporter:  rws                |        Owner:
           Type:  enhancement        |       Status:  new
       Priority:  major              |    Milestone:  sage-6.3
      Component:  packages:          |   Resolution:
  standard                           |    Merged in:
       Keywords:                     |    Reviewers:
        Authors:  Ralf Stephan       |  Work issues:
Report Upstream:  N/A                |       Commit:
         Branch:                     |  c280b72b302616eef2d5e0b94848fe8a02af091b
  u/rws/upgrade_sympy_to_version_0_7_5|     Stopgaps:
   Dependencies:                     |
-------------------------------------+-------------------------------------

Comment (by rws):

 Even with sympy-0.7.4 in a fresh Sage I get
 {{{
 sage:     import sage.libs.mpmath.ext_main as _mpf_module
 ---------------------------------------------------------------------------
 AttributeError                            Traceback (most recent call
 last)
 <ipython-input-1-06f00c8c1fbc> in <module>()
 ----> 1 import sage.libs.mpmath.ext_main as _mpf_module

 /home/ralf/sage/ext_main.pyx in init sage.libs.mpmath.ext_main
 (build/cythonized/sage/libs/mpmath/ext_main.c:28725)()

 /home/ralf/sage/local/lib/python2.7/site-packages/mpmath/__init__.py in
 <module>()
       4
       5 from .ctx_fp import FPContext
 ----> 6 from .ctx_mp import MPContext
       7 from .ctx_iv import MPIntervalContext
       8

 /home/ralf/sage/local/lib/python2.7/site-packages/mpmath/ctx_mp.py in
 <module>()
      47     from sage.libs.mpmath.ext_main import Context as BaseMPContext
      48     # pickle hack
 ---> 49     import sage.libs.mpmath.ext_main as _mpf_module
      50 else:
      51     from .ctx_mp_python import PythonMPContext as BaseMPContext

 AttributeError: 'module' object has no attribute 'ext_main'
 }}}
 This and the 0.7.5 failure both can be cured for example with
 {{{
 --- mpmath/libmp/backend.py~    2013-08-08 14:49:58.000000000 +0200
 +++ mpmath/libmp/backend.py     2014-07-11 08:54:28.759388954 +0200
 @@ -71,6 +71,7 @@
      try:
          import sage.all
          import sage.libs.mpmath.utils as _sage_utils
 +        import sage.libs.mpmath.ext_main as _mpf_module
          sage = sage.all
          sage_utils = _sage_utils
          BACKEND = 'sage'
 }}}
 So it seems `ext_main` has to be imported in the right place and there was
 somewhere an import in `sympy-0.7.4` that made that version work but that
 was changed in `0.7.5`. It does not work to simply catch the error and
 import again, while it works when in a fresh Sage with `0.7.4`.

--
Ticket URL: <http://trac.sagemath.org/ticket/16624#comment:4>
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 unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to