Ticket #12095 (confirmed Bug)

Opened 5 years ago

Last modified 4 years ago

18n-able error messages - products.validation

Reported by: ristow Owned by:
Priority: minor Milestone: 4.x
Component: Internationalization Version:
Keywords: Cc:

Description

Problem: The error messages from Products.validation.interfaces.IValidator aren't been properly translated.

Returning a simple i18n "Plone" domain works fine, but for example:

  • _("Error the id ${obj_id}",mapping={u"obj_id": objid}): losts the mapping
  • _("My Error message", domain="mydomain"): Do not translate (always using "Plone" domain)

Debugging: at Products/validation/chain.py:167:

            return '\n'.join([
                              #'%s: %s' % (name, res)
                              '%s' % res
                              for name, res in results.items()]
                            )

the "i18nmessageid" objects are been converted to strings and loosing information.

To fix: Is it possible to return an array of "i18nmessageid" objects here or maybe translate the messages in this point?

Change History

comment:1 Changed 4 years ago by kleist

  • Status changed from new to confirmed
  • Component changed from Archetypes to Internationalization
  • Milestone Ongoing deleted

Which Plone version please?

comment:2 Changed 4 years ago by kleist

  • Milestone set to 4.x
Note: See TracTickets for help on using tickets.