diff options
| author | Victor Stinner <victor.stinner@gmail.com> | 2014-07-25 11:05:43 (GMT) | 
|---|---|---|
| committer | Victor Stinner <victor.stinner@gmail.com> | 2014-07-25 11:05:43 (GMT) | 
| commit | d6766ae434fd09130863af913a8193641e51b91c (patch) | |
| tree | a656fd4cac961ee3c19348101ddfe6954dd9edcf /Lib/asyncio/proactor_events.py | |
| parent | 68a470f65d207419be1f40f8fec743a51529ca7e (diff) | |
| parent | 18a28dc5c28ae9a953f537486780159ddb768702 (diff) | |
| download | cpython-d6766ae434fd09130863af913a8193641e51b91c.zip cpython-d6766ae434fd09130863af913a8193641e51b91c.tar.gz cpython-d6766ae434fd09130863af913a8193641e51b91c.tar.bz2 | |
(Merge 3.4) asyncio: sync with Tulip
* Fix _WaitHandleFuture.cancel(): return the result of the parent cancel()
  method.
* _OverlappedFuture.cancel() now clears its reference to the overlapped object.
  Make also the _OverlappedFuture.ov attribute private.
* Check if _WaitHandleFuture completed before unregistering it in the callback.
  Add also _WaitHandleFuture._poll() and repr(_WaitHandleFuture).
* _WaitHandleFuture now unregisters its wait handler if WaitForSingleObject()
  raises an exception.
* _OverlappedFuture.set_exception() now cancels the overlapped operation.
Diffstat (limited to 'Lib/asyncio/proactor_events.py')
| -rw-r--r-- | Lib/asyncio/proactor_events.py | 8 | 
1 files changed, 2 insertions, 6 deletions
| diff --git a/Lib/asyncio/proactor_events.py b/Lib/asyncio/proactor_events.py index c530687..ab566b3 100644 --- a/Lib/asyncio/proactor_events.py +++ b/Lib/asyncio/proactor_events.py @@ -44,13 +44,9 @@ class _ProactorBasePipeTransport(transports._FlowControlMixin,      def __repr__(self):          info = [self.__class__.__name__, 'fd=%s' % self._sock.fileno()]          if self._read_fut is not None: -            ov = "pending" if self._read_fut.ov.pending else "completed" -            info.append('read=%s' % ov) +            info.append('read=%s' % self._read_fut)          if self._write_fut is not None: -            if self._write_fut.ov.pending: -                info.append("write=pending=%s" % self._pending_write) -            else: -                info.append("write=completed") +            info.append("write=%r" % self._write_fut)          if self._buffer:              bufsize = len(self._buffer)              info.append('write_bufsize=%s' % bufsize) | 
