Skip to content
Snippets Groups Projects

DOC: Update tutorial on error handling

Merged Florian Spreckelsen requested to merge f-doc-errors into dev
1 file
+ 19
11
Compare changes
  • Side-by-side
  • Inline
+ 19
11
@@ -47,10 +47,10 @@ errors<EntityError>` which you can inspect in order to learn why the
transaction failed. For this inspection, there are some helpful
attributes and methods provided by the ``TransactionError``:
* ``entities``: a set of all entities that caused at least one error
* ``entities``: a list of all entities that caused at least one error
in this transaction
* ``errors``: a set of all ``EntityError`` objects that occurred during
* ``errors``: a list of all ``EntityError`` objects that occurred during
the transaction.
* ``has_error(error_t)``: Check whether an error of type ``error_t``
@@ -78,12 +78,20 @@ with only one item—``[self]``.
Special Errors
~~~~~~~~~~~~~~
Subclasses of ``EntityError`` for special purposes: \*
``EntityDoesNotExistError`` \* ``EntityHasNoDataTypeError`` \*
``UniqueNamesError`` \* ``UnqualifiedParentsError`` - overrides
``get_entities()``: returns all parent entities with errors. - overrides
``get_errors()``: returns a list of EntityErrors which have been caused
by parent entities. \* ``UnqualifiedPropertiesError`` - overrides
``get_entities()``: returns all properties with errors. - overrides
``get_errors()``: returns a list of EntityErrors which have been caused
by properties.
Subclasses of ``EntityError`` for special purposes:
* ``EntityDoesNotExistError``
* ``EntityHasNoDataTypeError``
* ``UniqueNamesError``
* ``UnqualifiedParentsError``
* ``UnqualifiedPropertiesError``
* ``ConsistencyError``
* ``AuthorizationError``
* ``AmbiguousEntityError``
Loading