Releases: aio-libs/aiohttp
aiohttp 0.20.0 release
The release has many optimizations as well as other improvements and bug fixes.
The most notable ones:
- Use TCP_CORK/TCP_NOPUSH and TCP_NODELAY for disabling Nagle algorithm
- Reduce amount of syscalls for chunked encoding transfer
- Improve performance of websocket mask applying
- Round server timeouts to seconds for grouping pending calls
- Implement Class Based Views
- Fix broken support for https proxies with authentication
Full list of changes:
- Extend list of web exceptions, add HTTPMisdirectedRequest,
HTTPUpgradeRequired, HTTPPreconditionRequired, HTTPTooManyRequests,
HTTPRequestHeaderFieldsTooLarge, HTTPVariantAlsoNegotiates,
HTTPNotExtended, HTTPNetworkAuthenticationRequired status codes #644 - Do not remove AUTHORIZATION header by WSGI handler #649
- Fix broken support for https proxies with authentication #617
- Get REMOTE_* and SEVER_* http vars from headers when listening on
unix socket #654 - Add HTTP 308 support #663
- Add Tf format (time to serve request in seconds, %06f format) to
access log #669 - Remove one and a half years long deprecated
ClientResponse.read_and_close() method - Optimize chunked encoding: use a single syscall instead of 3 calls
on sending chunked encoded data - Use TCP_CORK and TCP_NODELAY to optimize network latency and
throughput #680 - Websocket XOR performance improved #687
- Avoid sending cookie attributes in Cookie header #613
- Round server timeouts to second for grouping pending call. That
leads to less amount of poller syscalls e.g epoll.poll(). #702 - Close connection on websocket handshake error #703
- Implement class based views #684
- Add headers parameter to ws_connect() #709
- Drop unused function
parse_remote_addr()#708 - Close session on exception #707
- Store http code and headers in WSServerHandshakeError #706
- Make some low-level message properties readonly #710
aiohttp 0.19.0
Major aiohttp 0.19.0 release
Highlighted features
async for support for websockets and client multiparts,
support redirects history for client requests,
Timeout context manager for limiting execution time of inner block.
Full list of changes
- Memory leak in ParserBuffer #579
- Suppport gunicorn's
max_requestssettings in gunicorn worker - Fix wsgi environment building #573
- Improve access logging #572
- Drop unused host and port from low-level server #586
- Add Python 3.5
async forimplementation to server websocket #543 - Add Python 3.5
async forimplementation to client websocket - Add Python 3.5
async withimplementation to client websocket - Add charset parameter to web.Response constructor #593
- Forbid passing both Content-Type header and content_type or charset
params into web.Response constructor - Forbid duplicating of web.Application and web.Request #602
- Add an option to pass Origin header in ws_connect #607
- Add json_response function #592
- Make concurrent connections respect limits #581
- Collect history of responses if redirects occur #614
- Enable passing pre-compressed data in requests #621
- Expose named routes via UrlDispatcher.named_routes() #622
- Allow disabling sendfile by environment variable AIOHTTP_NOSENDFILE #629
- Use ensure_future if available
- Always quote params for Content-Disposition #641
- Support async for in multipart reader #640
- Add Timeout context manager #611
aiohttp 0.18.4
Bugfix release.
Changes
- Relax rule for router names again by adding dash to allowed
characters: they may contain identifiers, dashes, dots and columns
aiohttp 0.18.3 bugfix release
Changes
- Fix formatting for _RequestContextManager helper #590
aiohttp 0.18.2
Bugfix release, fixes regression with usage OpenSSL < 1.0.0 #584
aiohttp 0.18.1
0.18.1 bugfix release
Changes
- Relax rule for router names: they may contain dots and columns
starting from now
aiohttp 0.18.0
Major aiohttp release.
Added support for async for and async with, e.g.
async with client.get(url) as resp:
async for line in resp.content:
print(line)
auto-closes response object and iterates over response's content.
Server-side signals added (allows, for example, setup http headers for long-living responses in signal hook).
Python 3.3 support dropped.
Full list of changes is pretty huge:
Changes
-
Use errors.HttpProcessingError.message as HTTP error reason and
message #459 -
Optimize cythonized multidict a bit
-
Change repr's of multidicts and multidict views
-
default headers in ClientSession are now case-insensitive
-
Make '=' char and 'wss://' schema safe in urls #477
-
ClientResponse.close()forces connection closing by default from now #479
N.B. Backward incompatible change: was.close(force=False) Usingforceparameter for the method is deprecated: use.release()` instead. -
Properly requote URL's path #480
-
add
skip_auto_headersparameter for client API #486 -
Properly parse URL path in aiohttp.web.Request #489
-
Raise RuntimeError when chunked enabled and HTTP is 1.0 #488
-
Fix a bug with processing io.BytesIO as data parameter for client API #500
-
Skip auto-generation of Content-Type header #507
-
Use sendfile facility for static file handling #503
-
Default
response_factoryinapp.router.add_staticnow is
StreamResponse, notNone. The functionality is not changed if
default is not specified. -
Drop
ClientResponse.messageattribute, it was always implementation detail. -
Streams are optimized for speed and mostly memory in case of a big
HTTP message sizes #496 -
Fix a bug for server-side cookies for dropping cookie and setting it
again without Max-Age parameter. -
Don't trim redirect URL in client API #499
-
Extend precision of access log "D" to milliseconds #527
-
Deprecate
StreamResponse.start()method in favor of
StreamResponse.prepare()coroutine #525.start()is still supported but responses begun with.start()
doesn't call signal for response preparing to be sent. -
Add
StreamReader.__repr__ -
Drop Python 3.3 support, from now minimal required version is Python
3.4.1 #541 -
Add
async withsupport forClientSession.request()and family #536 -
Ignore message body on 204 and 304 responses #505
-
TCPConnectorprocessed both IPv4 and IPv6 by default #559 -
Add
.routes()view for urldispatcher #519 -
Route name should be a valid identifier name from now #567
-
Implement server signals #562
-
Drop an year-old deprecated files parameter from client API.
-
Added
async forsupport for aiohttp stream #542
aiohttp 0.17.4 release
Minor aiohttp release.
The main change is making code pep-492 compatible.
So you can use await in client API, e.g.:
async def getter(url):
resp = await aiohttp.get(url)
try:
text = await resp.read()
return text
finally:
await resp.release()
Changes
- Properly parse URL path in aiohttp.web.Request #489
- Add missing coroutine decorator, the code is await-compatible now