Attribute parsing and error messages working