def flash_errors(form, category='danger'):
    for field, errors in form.errors.items():
        for error in errors:
            flash(
                (getattr(form, field).label.text, error) % u'%s - %s',
                category
            )
dataset/ETHPy150Open cburmeister/flask-bones/app/utils.py/flash_errors/swapped operands of `%`