Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4f9b773

Browse files
committed
asyncio doc: Fix doc of get and put methods of Queue
1 parent 10e76b6 commit 4f9b773

1 file changed

Lines changed: 13 additions & 8 deletions

File tree

Doc/library/asyncio-sync.rst

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ Queue
293293

294294
.. method:: full()
295295

296-
Return ``True`` if there are maxsize items in the queue.
296+
Return ``True`` if there are :attr:`maxsize` items in the queue.
297297

298298
.. note::
299299

@@ -302,12 +302,15 @@ Queue
302302

303303
.. method:: get()
304304

305-
Remove and return an item from the queue.
306-
307-
If you yield from :meth:`get()`, wait until a item is available.
305+
Remove and return an item from the queue. If queue is empty, wait until
306+
an item is available.
308307

309308
This method is a :ref:`coroutine <coroutine>`.
310309

310+
.. seealso::
311+
312+
The :meth:`empty` method.
313+
311314
.. method:: get_nowait()
312315

313316
Remove and return an item from the queue.
@@ -317,13 +320,15 @@ Queue
317320

318321
.. method:: put(item)
319322

320-
Put an item into the queue.
321-
322-
If you yield from ``put()``, wait until a free slot is available before
323-
adding item.
323+
Put an item into the queue. If the queue is full, wait until a free slot
324+
is available before adding item.
324325

325326
This method is a :ref:`coroutine <coroutine>`.
326327

328+
.. seealso::
329+
330+
The :meth:`full` method.
331+
327332
.. method:: put_nowait(item)
328333

329334
Put an item into the queue without blocking.

0 commit comments

Comments
 (0)