environment/lib/python2.7/site-packages/IPython/external/pexpect/_pexpect.py
def __interact_copy(self, escape_character = None, input_filter = None, output_filter = None):

        """This is used by the interact() method.
        """

        while self.isalive():
            r,w,e = self.__select([self.child_fd, self.STDIN_FILENO], [], [])
            if self.child_fd in r:
                data = self.__interact_read(self.child_fd)
                if output_filter: data = output_filter(data)
                if self.logfile is not None:
                    self.logfile.write (data)
                    self.logfile.flush()
                os.write(self.STDOUT_FILENO, data)
            if self.STDIN_FILENO in r:
                data = self.__interact_read(self.STDIN_FILENO)
                if input_filter: data = input_filter(data)
                i = data.rfind(escape_character)
                if i != -1:
                    data = data[:i]
                    self.__interact_writen(self.child_fd, data)
                    break
                self.__interact_writen(self.child_fd, data)
def __interact_copy(self, escape_character = None, input_filter = None, output_filter = None):

        """This is used by the interact() method.
        """

        while self.isalive():
            r,w,e = self.__select([self.child_fd, self.STDIN_FILENO], [], [])
            if self.child_fd in r:
                data = self.__interact_read(self.child_fd)
                if output_filter: data = output_filter(data)
                if self.logfile is not None:
                    self.logfile.write (data)
                    self.logfile.flush()
                os.write(self.STDOUT_FILENO, data)
            if self.STDIN_FILENO in r:
                data = self.__interact_read(self.STDIN_FILENO)
                if input_filter: data = input_filter(data)
                i = data.rfind(escape_character)
                if i != -1:
                    data = data[:i]
                    self.__interact_writen(self.child_fd, data)
                    break
                self.__interact_writen(self.child_fd, data)
def __interact_copy ( self , escape_character = None , input_filter = None , output_filter = None ) : while self . isalive ( ) : r , w , e = self . __select ( [ self . child_fd , self . STDIN_FILENO ] , [ ] , [ ] ) if self . child_fd in r : data = self . __interact_read ( self . child_fd ) if output_filter : data = output_filter ( data ) if self . logfile is not None : self . logfile . write ( data ) self . logfile . flush ( ) os . write ( self . STDOUT_FILENO , data ) if self . STDIN_FILENO in r : data = self . __interact_read ( self . STDIN_FILENO ) if input_filter : data = input_filter ( data ) i = data . rfind ( escape_character ) if i != - 1 : data = data [ : i ] self . __interact_writen ( self . child_fd , data ) break self . __interact_writen ( self . child_fd , data )
This is used by the interact() method.
This is used by the interact () method .