bento_meta.mdb.writeable
mdb.writeable: subclass of class:bento_meta.MDB to support writing to an MDB
Module Contents
Classes
Functions
|
Decorates a query function to run a write transaction based |
- bento_meta.mdb.writeable.write_txn(func)[source]
Decorates a query function to run a write transaction based on its query. Query function should return a tuple (qry_string, param_dict).
- class bento_meta.mdb.writeable.WriteableMDB(*args, **kwargs)[source]
Bases:
bento_meta.mdb.MDB
- put_term_with_origin(term, commit='', _from=1)[source]
Merge a bento-meta Term object, that has an Origin object set, into an MDB. If a new term is created, assign a random 6-char nanoid to it. The Origin must already be represented in the database. :param Term term: Term object :param str commit: GitHub commit SHA1 associated with the term (if any)