Files API Exceptions (Python)

Deprecation Notice: The Files API feature documented on this page, is deprecated as of May 21, 2013. This feature is sometimes referred to as the Google Cloud Storage API, and is schedule for shutdown as documented in the Files API Service Turndown page. It is replaced by the Google Cloud Storage Client Library. The documentation for the deprecated API is retained for the convenience of developers still using the Files API.

Note: The Files API was also known as the Google Cloud Storage API.

The google.appengine.api.files package exposes the following exception classes:

exception Error()

The base class for all exceptions in this package.

exception UnsupportedOpenModeError()

Raised by files.open() when it receives an unsupported open mode. The only modes supported are 'a', for write, or 'r', for read.

exception UnsupportedContentTypeError()

Raised by files.read() or files.write() when it cannot parse the content-type of the file for read or write.

exception InvalidArgumentError()

An invalid argument was passed.

exception FinalizationError()

The file is in the wrong finalization state. This can happen, for example, if you open a file for read and tried to finalize it.

exception ExistenceError()

The file you tried to open does not exist.

exception UnknownError()

An unknown error occurred.

exception InvalidFileNameError()

The file name is invalid.

exception FileNotOpenedError()

The file is not opened. You need to open a file before you can write or read from it.

exception ReadOnlyError()

The file is read only.

exception WrongOpenMode()

The file cannot be read because it is opened for write.

exception OperationNotSupported()

The operation you tried to perform is not supported.

exception PermissionDeniedError()

The application does not have permission to perform this operation.

exception ApiTemporaryUnavailableError()

The API is temporary unavailable. Your request will be retried soon.

exception FileTemporaryUnavailable()

The file is temporarily unavailable. Your request will be retried soon.

exception InvalidParameterError()

There was an invalid parameter in your request.