db.migrate#
- migrate(url: URL, error_queue: Queue[Exception] | None = None) None #
Runs migrations on the database. NB: Migrate only works on non-memory databases.
- Parameters:
url – The database URL.
- migrate_in_thread(url: URL) None #
Runs migrations on the database in a separate thread. This is needed because depending on the context (notebook) the migration process can fail to execute in the main thread.
- printif(condition: bool, text: str) None #