Go to the latest version of this document.
search in docstrings

Search bar offers the following options:

- Term presence. The below example searches for documents that must contain “foo”, might contain “bar” and must not contain “baz”: `+foo bar -baz`
- Wildcards. The below example searches for documents with words beginning with “foo”: `foo*`
- Search in specific fields. The following search matches all objects in "twisted.mail" that matches “search”: `+qname:twisted.mail.* +search`

  Possible fields: 'name', 'qname' (fully qualified name), 'docstring', and 'kind'. Last two fields are only applicable if "search in docstrings" is enabled.

- Fuzzy matches. The following search matches all documents that have a word within 1 edit distance of “foo”: `foo~1`

Results provided by Lunr.js

# ``twisted`.`internet`.`defer`.`FirstError``

exception documentation

`class FirstError(Exception): (source)`

View In Hierarchy

First error to occur in a `DeferredList` if `fireOnOneErrback` is set.

Method | `__cmp__` | Comparison between `FirstError` and other `FirstError` instances is defined as the comparison of the index and sub-failure of each instance. `FirstError` instances don't compare equal to anything that isn't a ...
Method | `__init__` | Undocumented
Method | `__repr__` | The repr of `FirstError` instances includes the repr of the wrapped failure's exception and the index of the `FirstError`.
Method | `__str__` | The str of `FirstError` instances includes the str of the entire wrapped failure (including its traceback and exception) and the index of the `FirstError`.
Instance Variable | `index` | The index of the `Deferred` in the `DeferredList` where it happened.
Instance Variable | `subFailure` | The `Failure` that occurred.

def __cmp__(self, other): (source)

Comparison between `FirstError` and other `FirstError` instances is defined as the comparison of the index and sub-failure of each instance. `FirstError` instances don't compare equal to anything that isn't a `FirstError` instance.

Parameters
other:`object` | Undocumented
Returns
`int` | Undocumented
Present Since
8.2

def __init__(self, failure, index): (source)

Undocumented

Parameters
failure:`Failure` | Undocumented
index:`int` | Undocumented

def __repr__(self): (source)

The repr of `FirstError` instances includes the repr of the wrapped failure's exception and the index of the `FirstError`.

Returns
`str` | Undocumented

def __str__(self): (source)

The str of `FirstError` instances includes the str of the entire wrapped failure (including its traceback and exception) and the index of the `FirstError`.

Returns
`str` | Undocumented

index = (source)

The index of the `Deferred` in the `DeferredList` where it happened.

subFailure = (source)

The `Failure` that occurred.