Commit 326e563f authored by Jason Madden's avatar Jason Madden

Simplify AsyncResult now that its keeping the exc_info around. Docs.

parent 105c1abe
...@@ -255,4 +255,4 @@ class MyClassDocumenter(ClassDocumenter): ...@@ -255,4 +255,4 @@ class MyClassDocumenter(ClassDocumenter):
members.sort(key=key) members.sort(key=key)
return members_check_module, members return members_check_module, members
#autodoc.ClassDocumenter = MyClassDocumenter autodoc.ClassDocumenter = MyClassDocumenter
...@@ -42,6 +42,12 @@ def generate_rst_for_module(module, do=True): ...@@ -42,6 +42,12 @@ def generate_rst_for_module(module, do=True):
m = getattr(m, module) m = getattr(m, module)
title = getattr(m, '__doc__', None) title = getattr(m, '__doc__', None)
if title: if title:
lines = title.strip().splitlines()
for line in lines:
# skip leading blanks. Support both styles of docstrings.
if line:
title = line
break
title = title.strip().split('\n')[0] title = title.strip().split('\n')[0]
title = title.strip(' .') title = title.strip(' .')
prefix = ':mod:`gevent.%s`' % module prefix = ':mod:`gevent.%s`' % module
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
.. method:: is_set() .. method:: is_set()
isSet() isSet()
ready()
Return true if and only if the internal flag is true. Return true if and only if the internal flag is true.
...@@ -15,8 +16,3 @@ ...@@ -15,8 +16,3 @@
.. autoclass:: gevent.event.AsyncResult .. autoclass:: gevent.event.AsyncResult
:members: :members:
:undoc-members: :undoc-members:
.. attribute:: value
Holds the value passed to :meth:`set` if :meth:`set` was called. Otherwise ``None``.
This diff is collapsed.
# Copyright (c) 2009-2011 Denis Bilenko. See LICENSE for details. # Copyright (c) 2009-2011 Denis Bilenko. See LICENSE for details.
"""
Waiting for I/O completion.
"""
from __future__ import absolute_import from __future__ import absolute_import
from gevent.event import Event from gevent.event import Event
from gevent.hub import get_hub from gevent.hub import get_hub
......
...@@ -4,11 +4,11 @@ ...@@ -4,11 +4,11 @@
This module provides socket operations and some related functions. This module provides socket operations and some related functions.
The API of the functions and classes matches the API of the corresponding The API of the functions and classes matches the API of the corresponding
items in standard :mod:`socket` module exactly, but the synchronous functions items in the standard :mod:`socket` module exactly, but the synchronous functions
in this module only block the current greenlet and let the others run. in this module only block the current greenlet and let the others run.
For convenience, exceptions (like :class:`error <socket.error>` and :class:`timeout <socket.timeout>`) For convenience, exceptions (like :class:`error <socket.error>` and :class:`timeout <socket.timeout>`)
as well as the constants from :mod:`socket` module are imported into this module. as well as the constants from the :mod:`socket` module are imported into this module.
""" """
import sys import sys
...@@ -43,7 +43,7 @@ def create_connection(address, timeout=_GLOBAL_DEFAULT_TIMEOUT, source_address=N ...@@ -43,7 +43,7 @@ def create_connection(address, timeout=_GLOBAL_DEFAULT_TIMEOUT, source_address=N
global default timeout setting returned by :func:`getdefaulttimeout` global default timeout setting returned by :func:`getdefaulttimeout`
is used. If *source_address* is set it must be a tuple of (host, port) is used. If *source_address* is set it must be a tuple of (host, port)
for the socket to bind as a source address before making the connection. for the socket to bind as a source address before making the connection.
An host of '' or port 0 tells the OS to use the default. A host of '' or port 0 tells the OS to use the default.
""" """
host, port = address host, port = address
......
"""
Secure Sockets Layer (SSL/TLS) module.
"""
from gevent.hub import PY3 from gevent.hub import PY3
from gevent.hub import PYGTE279 from gevent.hub import PYGTE279
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment