scene_pipelines.core.db
Small DataJoint helpers shared by the write paths (ids, transactions, key lookup).
atomic
Open a transaction, or join the one already open (DataJoint cannot nest).
lookup_key
lookup_key(table: type[Manual], restriction: DjKey) -> DjKey | None
Return the primary key of the row matching restriction, or None.
restriction should cover a unique index (e.g. lab_id + a code), so
at most one row matches.