Where to call sqlalchemy configure_mappers with multiple Python modules

504 views Asked by At

I have a multiple class sqlalchemy implemented model. It spans multiple Python modules and includes relationships that reach across those modules as well. I want to add versioning to my model and I've decided to use sqlalchemy-continuum.

In sqlalchemy-continuum's documentation it says "after you have defined all your models, call configure_mappers:". But they use a single Python module as an example.

Question: When using a multiple Python modules to implement a sqlalchemy model, where should sqlalchemy's utility function configure_mappers be called so that it its only called after all models have been defined?

0

There are 0 answers