'Push one or more lines of IPython input.
This stores the given lines and returns a status code indicating
whether the code forms a complete Python block or not, after processing
all input lines for special IPython syntax.
Any exceptions generated in compilation are swallowed, but if an
exception was produced, the method returns True.
Parameters
lines : string
One or more lines of Python input.
Returns
is_complete : boolean
True if the current input source (the result of the current input
plus prior inputs) forms a complete Python execution block.  Note that
this value is also stored as a private attribute (_is_complete), so it
can be queried at any time.'

def push(self, lines):

    lines = cast_unicode(lines, self.encoding)
    lines_list = lines.splitlines()
    if (not lines_list):
        lines_list = ['']
    self._store(lines, self._buffer_raw, 'source_raw')
    for line in lines_list:
        out = self.push_line(line)
    return out
