@declared_attr
    def created_by(cls):
        return relationship("MyUser", primaryjoin=cls.__name__ % '%s.created_by_fk == MyUser.id', enable_typechecks=False)
dataset/ETHPy150Open dpgaspar/Flask-AppBuilder/examples/extendsecurity/app/models.py/Contact.created_by/swapped operands of `%`