db_connector
Helper class to connect to local SQLite database.
Classes
DbConnector
class DbConnector(pod_db_path: Optional[Path] = None):
Database connector to local SQLite database.
Arguments
pod_db_path
: Optional path to the directory where the SQLite database files are stored. Defaults to None.
Subclasses
Variables
- static
db_files_location : Optional[pathlib.Path]
ProjectDbConnector
class ProjectDbConnector(pod_db_path: Optional[Path] = None):
Database connector to local project SQLite database.
Arguments
pod_db_path
: Optional path to the directory where the SQLite database files for the project are stored. Defaults to None.
Ancestors
Methods
get_project_db_connection
def get_project_db_connection(self, project_id: str) ‑> sqlite3.Connection:
Establishes a connection to the database given a project id.
Returns Connection: The connection to the SQLite DB.