maestral.exceptions =================== .. py:module:: maestral.exceptions .. autoapi-nested-parse:: This module defines Maestral's error classes. It should be kept free of memory heavy imports. All errors inherit from :exc:`MaestralApiError` which has title and message attributes to display the error to the user. Errors which are related to syncing a specific file or folder inherit from :exc:`SyncError`, a subclass of :exc:`MaestralApiError`. Module Contents --------------- .. py:exception:: MaestralApiError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`Exception` Base class for Maestral errors MaestralApiError provides attributes that can be used to generate human-readable error messages and metadata regarding affected file paths (if any). Errors originating from the Dropbox API or the 'local API' both inherit from MaestralApiError. :param title: A short description of the error type. This can be used in a CLI or GUI to give a short error summary. :param message: A more verbose description which can include instructions on how to proceed to fix the error. :param dbx_path: Dropbox path of the item that caused the error. :param dbx_path_from: Dropbox origin path of the item that caused the error. This should be set for instance when error occurs when moving an item. :param local_path: Local path of the item that caused the error. :param local_path_from: Local origin path of the item that caused the error. This should be set for instance when error occurs when moving an item. .. py:exception:: SyncError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Base class for recoverable sync issues. .. py:exception:: DataCorruptionError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when data is corrupted in transit during upload or download. .. py:exception:: DataChangedError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when file changes during upload. .. py:exception:: InsufficientPermissionsError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when accessing a file or folder fails due to insufficient permissions, both locally and on Dropbox servers. .. py:exception:: InsufficientSpaceError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when the Dropbox account or local drive has insufficient storage space. .. py:exception:: PathError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when there is an issue with the provided file or folder path such as invalid characters or a too long file name. .. py:exception:: NotFoundError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when a file or folder is requested but does not exist. .. py:exception:: ConflictError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when trying to create a file or folder which already exists. .. py:exception:: FileConflictError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`ConflictError` Raised when trying to create a file which already exists. .. py:exception:: FolderConflictError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when trying to create or folder which already exists. .. py:exception:: IsAFolderError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when a file is required but a folder is provided. .. py:exception:: NotAFolderError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when a folder is required but a file is provided. .. py:exception:: DropboxServerError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised in case of internal Dropbox errors. .. py:exception:: RestrictedContentError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when trying to sync restricted content, for instance when adding a file with a DMCA takedown notice to a public folder. .. py:exception:: UnsupportedFileError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when this file type cannot be downloaded but only exported. This is the case for G-suite files. .. py:exception:: FileSizeError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when attempting to upload a file larger than 350 GB in an upload session or larger than 150 MB in a single upload. Also raised when attempting to download a file with a size that exceeds file system's limit. .. py:exception:: FileReadError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when reading a local file failed. .. py:exception:: SymlinkError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`SyncError` Raised when we cannot sync a symlink. .. py:exception:: DropboxConnectionError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when the connection to Dropbox fails .. py:exception:: CancelledError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when syncing is cancelled by the user. .. py:exception:: NotLinkedError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when no Dropbox account is linked. .. py:exception:: InvalidDbidError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when the given Dropbox ID does not correspond to an existing account. .. py:exception:: KeyringAccessError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when retrieving a saved auth token from the user keyring fails. .. py:exception:: NoDropboxDirError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when the local Dropbox folder cannot be found. .. py:exception:: CacheDirError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when creating the cache directory fails. .. py:exception:: InotifyError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when the local Dropbox folder is too large to monitor with inotify. .. py:exception:: OutOfMemoryError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when there is insufficient memory to complete an operation. .. py:exception:: DatabaseError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when reading or writing to the database fails. .. py:exception:: DropboxAuthError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when authentication fails. .. py:exception:: TokenExpiredError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`DropboxAuthError` Raised when authentication fails because the user's token has expired. .. py:exception:: TokenRevokedError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`DropboxAuthError` Raised when authentication fails because the user's token has been revoked. .. py:exception:: CursorResetError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when the cursor used for a longpoll or list-folder request has been invalidated. Dropbox will very rarely invalidate a cursor. If this happens, a new cursor for the respective folder has to be obtained through files_list_folder. This may require re-syncing the entire Dropbox. .. py:exception:: BadInputError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when an API request is made with bad input. This should not happen during syncing but only in case of manual API calls. .. py:exception:: BusyError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when trying to perform an action which is only possible in the idle state and we cannot block or queue the job. .. py:exception:: UnsupportedFileTypeForDiff(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when a diff for an unsupported file type was issued. .. py:exception:: SharedLinkError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when creating a shared link fails. .. py:exception:: PathRootError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when making an API call with an invalid path root header. .. py:exception:: UpdateCheckError(title, message = '', dbx_path = None, dbx_path_from = None, local_path = None, local_path_from = None) Bases: :py:obj:`MaestralApiError` Raised when checking for updates fails.