[IPython-dev] splitter not transforming a line

Jason Grout jason-sage at creativetrax.com
Tue Sep 25 08:22:50 EDT 2012

In the input splitter at 
it appears that the test makes sure that the "def" line in the below 
code is not run through the transformer:

def f(n=1):
     print n

Since it is not complete and the buffer has the @interact line in it and 
the @interact line does not end with ':' or ',', the transform is never 
run.  This is a big problem for Sage, since Sage wants to transform that 
1 to Integer(1) in the preparser.

Is this intentional?  There seem to be enough comments like 
that indicate that maybe this is an oversight in a tricky part of the code.



More information about the IPython-dev mailing list