Skip to content

Commit

Permalink
Fix "Usage" docstring of aiohttp.client.request
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomas S authored Mar 19, 2020
1 parent 913cd44 commit 693ed0c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGES/4603.doc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixed wrong "Usage" docstring of ``aiohttp.client.request``.
8 changes: 4 additions & 4 deletions aiohttp/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1130,10 +1130,10 @@ def request(
total timeout by default.
Usage::
>>> import aiohttp
>>> resp = await aiohttp.request('GET', 'http://python.org/')
>>> resp
<ClientResponse(python.org/) [200]>
>>> data = await resp.read()
>>> async with aiohttp.request('GET', 'http://python.org/') as resp:
... print(resp)
... data = await resp.read()
<ClientResponse(https://www.python.org/) [200 OK]>
"""
connector_owner = False
if connector is None:
Expand Down

0 comments on commit 693ed0c

Please sign in to comment.