Errors#

calendaring-sync’s error hierarchy.

Every error the library raises on purpose derives from CalendaringSyncError. A call with an argument that can never be valid, such as a negative cursor, raises ValueError instead.

exception calendaring_sync.error.CalendaringSyncError[source]#

Bases: Exception

Base for every calendaring-sync error.

exception calendaring_sync.error.DuplicateObjectError[source]#

Bases: CalendaringSyncError

Another record in the scope already has this object id.

exception calendaring_sync.error.ScopeMismatchError[source]#

Bases: CalendaringSyncError

A session was opened with a media type the scope doesn’t have.

The stored content is in the scope’s media type, so it can’t be reused. Drop the scope and sync it again.

exception calendaring_sync.error.SessionError[source]#

Bases: CalendaringSyncError

A session was used out of order.

For example a second session on a scope that already has one open, an ingest after the session’s last page, or a reset while a session is open.

exception calendaring_sync.error.StaleChangeSetError[source]#

Bases: CalendaringSyncError

A change set was fetched from a token the scope no longer has.

Another process ingested first, or started another listing of the same scope. The changes it fetched are already outdated, so the adapter fetches again from the scope’s current token.

exception calendaring_sync.error.StoreBusyError[source]#

Bases: StoreError

Another process kept the store busy for longer than the store waits.

Nothing was changed. Try again later.

exception calendaring_sync.error.StoreError[source]#

Bases: CalendaringSyncError

The store couldn’t read or write its data, such as a file that isn’t a store.

exception calendaring_sync.error.StoreVersionError[source]#

Bases: StoreError

The store was written by a newer calendaring-sync, with a schema this one can’t read.

exception calendaring_sync.error.TransactionError[source]#

Bases: CalendaringSyncError

A store transaction was used the wrong way.

Raised for a transaction opened while the thread already has one, and for closing the store inside a transaction. Its subclasses cover an operation outside a transaction and a write inside a read.

exception calendaring_sync.error.TransactionPermissionError[source]#

Bases: TransactionError

A store operation that writes ran in a transaction opened with write=False.

exception calendaring_sync.error.TransactionRequiredError[source]#

Bases: TransactionError

A store operation ran outside a transaction.

exception calendaring_sync.error.TrimmedFeedError[source]#

Bases: CalendaringSyncError

A cursor is older than the oldest change feed entry kept.

The entries after the cursor were trimmed, so they can’t be read. Read the scope’s records again, and continue from feed_head().

exception calendaring_sync.error.UnexpectedStoreError[source]#

Bases: CalendaringSyncError

A store failed in a way it doesn’t expect, which is a bug in it or its caller.

It isn’t a StoreError, so code that retries on a store error doesn’t retry a bug. The original exception is its __cause__.

exception calendaring_sync.error.UnknownRecordError[source]#

Bases: CalendaringSyncError

The store has no record with this local key.

exception calendaring_sync.error.UnknownScopeError[source]#

Bases: CalendaringSyncError

The store has no scope with this id.

Last updated on 2026-10-13.