#12719: Upgrade to IPython 0.13
----------------------------------------------------------+-----------------
       Reporter:  kini                                    |         Owner:  tbd 
                                  
           Type:  enhancement                             |        Status:  
needs_work                            
       Priority:  critical                                |     Milestone:  
sage-5.1                              
      Component:  packages                                |    Resolution:      
                                  
       Keywords:  sd40.5                                  |   Work issues:  ?? 
doesn't show code                  
Report Upstream:  N/A                                     |     Reviewers:  
Volker Braun, Mike Hansen, Jason Grout
        Authors:  Mike Hansen, Volker Braun, Jason Grout  |     Merged in:      
                                  
   Dependencies:                                          |      Stopgaps:      
                                  
----------------------------------------------------------+-----------------

Comment (by jason):

 Replying to [comment:76 jason]:
 > Fernando:  I looked in the IPython source, and it seems that IPython is
 a little more subtle than mentioned above.  By default, it only executes
 the last block as interactive (compile in 'single' mode) ''if it is an
 expression''. In Sage, we (by default) execute the last block always in
 'single' mode.  I think that is the difference here.
 >
 > Given that (and if I understood correctly), could you explain again your
 reasoning for choosing to not compile in 'single' mode if it isn't an
 expression?

 And here is Fernando's response:

 Precisely so that if the last block has a loop, it doesn't produce
 multiple `Out [NN]` cells.  We want to keep a one-to-one mapping between a
 cell and its output.  For example it's quite common to write code like:

 {{{
 for i in x:
   plot(x[i], label='blah_i')
 }}}

 If we compile that as 'single', we'd get all the Matplotlib line
 collection results piling up at the bottom, one for each plot call.

 We played a *lot* with various options, and settled on this behavior after
 much experimentation.  After 2 years of using it, I remain convinced it's
 the right solution *for us*.  Not to say that Sage can't make a different
 choice that works better for you guys, of course!

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