This can be resolved by explicitly populating the Association tables, instead of letting SQLAlchemy do it, I think.