
                            S r  " S S\5      r " S S\5      r " S S\5      r " S S\5      r " S	 S
\5      r " S S\5      r " S S\5      r " S S\5      r	 " S S\5      r
 " S S\5      r " S S\5      r " S S\5      r " S S\5      r " S S\5      r " S S\5      r " S S \5      r " S! S"\5      r " S# S$\5      rg%)&z(Errors used in the Python datastore API.c                       \ rS rSrSrSrg)Error   zBase datastore error type.
   N__name__
__module____qualname____firstlineno____doc____static_attributes__r       4lib/googlecloudsdk/appengine/api/datastore_errors.pyr   r          r   r   c                       \ rS rSrSrSrg)BadValueError    zyRaised by Entity.__setitem__(), Query.__setitem__(), Get(), and others
when a property value or filter value is invalid.
r   Nr   r   r   r   r   r           r   r   c                       \ rS rSrSrSrg)BadPropertyError%   zFRaised by Entity.__setitem__() when a property name isn't a string.
  r   Nr   r   r   r   r   r   %   r   r   r   c                       \ rS rSrSrSrg)BadRequestError)   z?Raised by datastore calls when the parameter(s) are invalid.
  r   Nr   r   r   r   r   r   )   r   r   r   c                       \ rS rSrSrSrg)EntityNotFoundError-   zFDEPRECATED: Raised by Get() when the requested entity is not found.
  r   Nr   r   r   r   r   r   -   r   r   r   c                       \ rS rSrSrSrg)BadArgumentError1   z^Raised by Query.Order(), Iterator.Next(), and others when they're
passed an invalid argument.
r   Nr   r   r   r   r   r   1   r   r   r   c                       \ rS rSrSrSrg)QueryNotFoundError6   zDEPRECATED: Raised by Iterator methods when the Iterator is invalid. This
should not happen during normal usage; it protects against malicious users
and system errors.
r   Nr   r   r   r   r!   r!   6   s    r   r!   c                       \ rS rSrSrSrg)TransactionNotFoundError<   z\DEPRECATED: Raised by RunInTransaction. This is an internal error; you
should not see this.
r   Nr   r   r   r   r$   r$   <   r   r   r$   c                       \ rS rSrSrSrg)RollbackA   zMay be raised by transaction functions when they want to roll back
instead of committing. Note that *any* exception raised by a transaction
function will cause a rollback. This is purely for convenience. See
datastore.RunInTransaction for details.
r   Nr   r   r   r   r'   r'   A       r   r'   c                       \ rS rSrSrSrg)TransactionFailedErrorH   zRaised by RunInTransaction methods when the transaction could not be
committed, even after retrying. This is usually due to high contention.
r   Nr   r   r   r   r+   r+   H   r   r   r+   c                   ,   ^  \ rS rSrSrU 4S jrSrU =r$ )BadFilterErrorM   zORaised by Query.__setitem__() and Query.Run() when a filter string is
invalid.
c                 t   > Xl         SU R                   -  R                  S5      n[        [        U ]  U5        g )Nzinvalid filter: %s.zutf-8)filterencodesuperr.   __init__)selfr1   message	__class__s      r   r4   BadFilterError.__init__Q   s0    K%3;;GDG	.$(1r   )r1   )r   r   r	   r
   r   r4   r   __classcell__r7   s   @r   r.   r.   M   s    2 2r   r.   c                       \ rS rSrSrSrg)BadQueryErrorV   z;Raised by Query when a query or query string is invalid.
  r   Nr   r   r   r   r<   r<   V   r   r   r<   c                       \ rS rSrSrSrg)BadKeyErrorZ   z1Raised by Key.__str__ when the key is invalid.
  r   Nr   r   r   r   r?   r?   Z   r   r   r?   c                       \ rS rSrSrSrg)InternalError^   z=An internal datastore error. Please report this to Google.
  r   Nr   r   r   r   rB   rB   ^   r   r   rB   c                   L   ^  \ rS rSrSr  S	U 4S jjrS rS rS rS r	Sr
U =r$ )
NeedIndexErrorb   zNo matching index was found for a query that requires an index. Check
the Indexes page in the Admin Console and your index.yaml file.
c                 \   > [         [        U ]  U5        X l        X0l        X@l        XPl        g N)r3   rE   r4   _original_message_header_yaml_index
_xml_index)r5   errororiginal_messageheader
yaml_index	xml_indexr7   s         r   r4   NeedIndexError.__init__g   s(    	.$(/-L!Or   c                     U R                   $ rH   )rI   r5   s    r   OriginalMessageNeedIndexError.OriginalMessageo   s    !!!r   c                     U R                   $ rH   )rJ   rT   s    r   HeaderNeedIndexError.Headerr   s    <<r   c                     U R                   $ rH   )rK   rT   s    r   	YamlIndexNeedIndexError.YamlIndexu   s    r   c                     U R                   $ rH   )rL   rT   s    r   XmlIndexNeedIndexError.XmlIndexx   s    ??r   )rJ   rI   rL   rK   )NNNN)r   r   r	   r
   r   r4   rU   rX   r[   r^   r   r9   r:   s   @r   rE   rE   b   s0     LP " r   rE   c                       \ rS rSrSrSrg)ReferencePropertyResolveError{   z>An error occurred while trying to resolve a ReferenceProperty.r   Nr   r   r   r   ra   ra   {   s    Fr   ra   c                       \ rS rSrSrSrg)Timeout   zThe datastore operation timed out, or the data was temporarily
unavailable. This can happen when you attempt to put, get, or delete too
many entities or an entity with too many properties, or if the datastore is
overloaded or having trouble.
r   Nr   r   r   r   rd   rd      r)   r   rd   c                       \ rS rSrSrSrg)CommittedButStillApplying   zThe write or transaction was committed, but some entities or index rows
may not have been fully updated. Those updates should automatically be
applied soon. You can roll them forward immediately by reading one of the
entities inside a transaction.
r   Nr   r   r   r   rg   rg      r)   r   rg   N)r   	Exceptionr   r   r   r   r   r   r!   r$   r'   r+   r.   r<   r?   rB   rE   ra   rd   rg   r   r   r   <module>rj      s    /I E 
u e % u 
 u 
u U 
2U 2E % E U 2GE Ge  r   