Powered by Tachyonic Project Luxon Framework v1.4.0

Luxon Framework for rapid application development. (luxon)


Model Utilities

Backup Tables


Makes a backup of a database

Retrieves the models in use and returns the corresponding tables and their entries from the database

Parameters:conn (connection object) – connection object for the database
Returns:Dictionary containing all tables in the database. Each entry is a list(rows) of sequences(elements in row) with the key being the table name

Drop Tables


Empties database

Deletes all the tables in a database that correspond to models in use

Parameters:conn (connection object) – the database to be deleted

Create Tables


Creates tables for all models in g.models

Restore Tables

luxon.core.utils.models.restore_tables(conn, backup)[source]

Restores database from backup

  • conn (connection object) – connection object of the database
  • backup (dict) – backup dictionary