Use SQLAlchemy to manage the DB
dune-perftest currently uses python's sqlite3
module to access the database. This follows pythons DBAPI v2 guidelines -- which give db modules quite some freedom in how they define their interfaces, in particular in how parameters are interpolated into queries. And db modules do make use of this freedom, which is a problem because for the HPC2SE project we need to talk to MariaDB.
SQLAlchemy provides a low level abstraction over the differences of particular db modules, which can itself be used according to DBAPI v2, or very close to it. So this looks like a good way to support both SQLite and MariaDB. (SQLAlchemy also supports high level ORM abstractions, but using those would probably involve redesigning major parts of dune-preftool)