Exceptions¶
Classes representing legacy Google App Engine exceptions.
Unless otherwise noted, these are meant to act as shims for the exception
types defined in the google.appengine.api.datastore_errors module in
legacy Google App Engine runtime.
-
exception
google.cloud.ndb.exceptions.ContextError[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorIndicates an NDB call being made without a context.
Raised whenever an NDB call is made outside of a context established by
google.cloud.ndb.client.Client.context().
-
exception
google.cloud.ndb.exceptions.BadValueError[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorIndicates a property value or filter value is invalid.
Raised by
Entity.__setitem__(),Query.__setitem__(),Get(), and others.
-
exception
google.cloud.ndb.exceptions.BadArgumentError[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorIndicates an invalid argument was passed.
Raised by
Query.Order(),Iterator.Next(), and others.
-
exception
google.cloud.ndb.exceptions.BadRequestError[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorIndicates a bad request was passed.
Raised by
Model.non_transactional()and others.
-
exception
google.cloud.ndb.exceptions.Rollback[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorAllows a transaction to be rolled back instead of committed.
Note that any exception raised by a transaction function will cause a rollback. Hence, this exception type is purely for convenience.
-
exception
google.cloud.ndb.exceptions.BadQueryError[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorRaised by Query when a query or query string is invalid.
-
exception
google.cloud.ndb.exceptions.BadFilterError(filter)[source]¶ Bases:
google.cloud.ndb.exceptions.ErrorIndicates a filter value is invalid.
Raised by
Query.__setitem__()andQuery.Run()when a filter string is invalid.