Permalink
Browse files

Declare what exceptions are raised by a couple routines.

  • Loading branch information...
1 parent 2364f39 commit e3372e15f75acaf7c6b7fb3f809c8e8ab1f6239f @erikrose erikrose committed Mar 19, 2013
Showing with 6 additions and 0 deletions.
  1. +6 −0 pyelasticsearch/client.py
@@ -681,6 +681,9 @@ def create_index(self, index, settings=None, query_params=None):
:arg index: The name of the index to create
:arg settings: A dictionary of settings
+ If the index already exists, raise
+ :class:`~pyelasticsearch.exceptions.IndexAlreadyExistsError`.
+
See `ES's create-index API`_ for more detail.
.. _`ES's create-index API`:
@@ -696,6 +699,9 @@ def delete_index(self, index, query_params=None):
:arg index: An index or iterable thereof to delete
+ If the index is not found, raise
+ :class:`~pyelasticsearch.exceptions.ElasticHttpNotFoundError`.
+
See `ES's delete-index API`_ for more detail.
.. _`ES's delete-index API`:

0 comments on commit e3372e1

Please sign in to comment.