summaryrefslogtreecommitdiff
path: root/ChangeLog
blob: e483fb2debfad2364ecfe478bd75a74e004ace26 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
2014-09-30: Tulip 3.4.2
=======================

New shiny methods like create_task(), better documentation, much better debug
mode, better tests.

asyncio API
-----------

* Add BaseEventLoop.create_task() method: schedule a coroutine object.
  It allows other asyncio implementations to use their own Task class to
  change its behaviour.

* New BaseEventLoop methods:

  - create_task(): schedule a coroutine
  - get_debug()
  - is_closed()
  - set_debug()

* Add _FlowControlMixin.get_write_buffer_limits() method

* sock_recv(), sock_sendall(), sock_connect(), sock_accept() methods of
  SelectorEventLoop now raise an exception if the socket is blocking mode

* Include unix_events/windows_events symbols in asyncio.__all__.
  Examples: SelectorEventLoop, ProactorEventLoop, DefaultEventLoopPolicy.

* attach(), detach(), loop, active_count and waiters attributes of the Server
  class are now private

* BaseEventLoop: run_forever(), run_until_complete() now raises an exception if
  the event loop was closed

* close() now raises an exception if the event loop is running, because pending
  callbacks would be lost

* Queue now accepts a float for the maximum size.

* Process.communicate() now ignores BrokenPipeError and ConnectionResetError
  exceptions, as Popen.communicate() of the subprocess module


Performances
------------

* Optimize handling of cancelled timers


Debug
-----

* Future (and Task), CoroWrapper and Handle now remembers where they were
  created (new _source_traceback object), traceback displayed when errors are
  logged.

* On Python 3.4 and newer, Task destrutor now logs a warning if the task was
  destroyed while it was still pending. It occurs if the last reference
  to the task was removed, while the coroutine didn't finish yet.

* Much more useful events are logged:

  - Event loop closed
  - Network connection
  - Creation of a subprocess
  - Pipe lost
  - Log many errors previously silently ignored
  - SSL handshake failure
  - etc.

* BaseEventLoop._debug is now True if the envrionement variable
  PYTHONASYNCIODEBUG is set

* Log the duration of DNS resolution and SSL handshake

* Log a warning if a callback blocks the event loop longer than 100 ms
  (configurable duration)

* repr(CoroWrapper) and repr(Task) now contains the current status of the
  coroutine (running, done), current filename and line number, and filename and
  line number where the object was created

* Enhance representation (repr) of transports: add the file descriptor, status
  (idle, polling, writing, etc.), size of the write buffer, ...

* Add repr(BaseEventLoop)

* run_until_complete() doesn't log a warning anymore when called with a
  coroutine object which raises an exception.


Bugfixes
--------

* windows_utils.socketpair() now ensures that sockets are closed in case
  of error.

* Rewrite bricks of the IocpProactor() to make it more reliable

* IocpProactor destructor now closes it.

* _OverlappedFuture.set_exception() now cancels the overlapped operation.

* Rewrite _WaitHandleFuture:

  - cancel() is now able to signal the cancellation to the overlapped object
  - _unregister_wait() now catchs and logs exceptions

* PipeServer.close() (class used on Windows) now cancels the accept pipe
  future.

* Rewrite signal handling in the UNIX implementation of SelectorEventLoop:
  use the self-pipe to store pending signals instead of registering a
  signal handler calling directly _handle_signal(). The change fixes a
  race condition.

* create_unix_server(): close the socket on error.

* Fix wait_for()

* Rewrite gather()

* drain() is now a classic coroutine, no more special return value (empty
  tuple)

* Rewrite SelectorEventLoop.sock_connect() to handle correctly timeout

* Process data of the self-pipe faster to accept more pending events,
  especially signals written by signal handlers: the callback reads all pending
  data, not only a single byte

* Don't try to set the result of a Future anymore if it was cancelled
  (explicitly or by a timeout)

* CoroWrapper now works around CPython issue #21209: yield from & custom
  generator classes don't work together, issue with the send() method. It only
  affected asyncio in debug mode on Python older than 3.4.2


Misc changes
------------

* windows_utils.socketpair() now supports IPv6.

* Better documentation (online & docstrings): fill remaining XXX, more examples

* new asyncio.coroutines submodule, to ease maintenance with the trollius
  project: @coroutine, _DEBUG, iscoroutine() and iscoroutinefunction() have
  been moved from asyncio.tasks to asyncio.coroutines

* Cleanup code, ex: remove unused attribute (ex: _rawsock)

* Reuse os.set_blocking() of Python 3.5.

* Close explicitly the event loop in Tulip examples.

* runtests.py now mention if tests are running in release or debug mode.

2014-05-19: Tulip 3.4.1
=======================

2014-02-24: Tulip 0.4.1
=======================

2014-02-10: Tulip 0.3.1
=======================

* Add asyncio.subprocess submodule and the Process class.

2013-11-25: Tulip 0.2.1
=======================

* Add support of subprocesses using transports and protocols.

2013-10-22: Tulip 0.1.1
=======================

* First release.

Creation of the project
=======================

* 2013-10-14: The tulip package was renamed to asyncio.
* 2012-10-16: Creation of the Tulip project, started as mail threads on the
  python-ideas mailing list.