The forms.errors dict seems to be sorted on field name, and not on the order they are declared in the form itself.
E.g.
class ProductForm(Form):
code = TextField('Code', validators=[Required()])
description = TextField('Description', validators=[Required(), Length(max=100)])
amount = DecimalField('Amount', validators=[Required(), NumberRange(min=0.00, max=1000000.00)])
vat_percentage = DecimalField('VAT %', validators=[Required(), NumberRange(min=0.00, max=100.00)])
inactive_date = DateField('Inactive date', validators=[Optional()])
Which produces the form.errors like:
{'amount': ['Amount is required'], 'code': ['Code is invalid.'],
'description': ['Description is required'], 'vat_percentage': ['VAT % is required']}
What I would like to do is print the the errors in the order as they are ordered in the form.
Is this possible?