Skip to content

trulens.core.database.exceptions

trulens.core.database.exceptions

Classes

DatabaseVersionException

Bases: Exception

Exceptions for database version problems.

Classes
Reason

Bases: Enum

Reason for the version exception.

Attributes
AHEAD class-attribute instance-attribute
AHEAD = 1

Initialized database is ahead of the stored version.

BEHIND class-attribute instance-attribute
BEHIND = 2

Initialized database is behind the stored version.

RECONFIGURED class-attribute instance-attribute
RECONFIGURED = 3

Initialized database differs in configuration compared to the stored version.

Configuration differences recognized
  • table_prefix
Functions
ahead classmethod
ahead()

Create an ahead variant of this exception.

behind classmethod
behind()

Create a behind variant of this exception.

reconfigured classmethod
reconfigured(prior_prefix: str)

Create a reconfigured variant of this exception.

The only present reconfiguration that is recognized is a table_prefix change. A guess as to the prior prefix is included in the exception and message.