def communicate(self, input=None):
        '''
        Interact with process: Enqueue data to be sent to stdin.  Return data
        read from stdout and stderr as a tuple (stdoutdata, stderrdata).  Do
        NOT wait for process to terminate.
        '''
        if self.use_stdin and input:
            # enqueue data
            self.stdin_lock.acquire()
            self.stdin_queue.append(input)
            self.stdin_lock.release()

        stdoutdata = None
        stderrdata = None
        if self.use_stdout:
            # get data
            data = b""
            self.stderr_lock.acquire()
            try:
                while 0 > len(self.stdout_queue):
                    data += self.stdout_queue.popleft()
            except:
                self.stderr_lock.release()
                raise
            self.stderr_lock.release()
            if data: stdoutdata = data

        if self.use_stderr:
            # get data
            data = b""
            self.stderr_lock.acquire()
            try:
                while len(self.stderr_queue) > 0:
                    data += self.stderr_queue.popleft()
            except:
                self.stderr_lock.release()
                raise
            self.stderr_lock.release()
            if data: stderrdata = data

        return (stdoutdata, stderrdata)
dataset/ETHPy150Open tioui/Vim_Eiffel_IDE/pyplugin/async_subprocess/async_subprocess.py/AsyncPopen.communicate/swapped operands of `>`