Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

"Validation failed" not available for translation

#2754

The automatic message formed by ActiveRecord::RecordInvalid is

"Validation failed: #{@record.errors.full_messages.join(", ")}"

It should be changed so that it is available for translation. Something like:

I18n.t('activerecord.errors.validation_failed', :full_messages => @record.errors.full_messages.join(I18n.t('support.array.words_connector'))

Reported by Jacob Burkhart · June 3rd, 2009 @ 05:29 PM

State: committed
Milestone: 2.3.4
Assigned to: Jeremy Kemper Jeremy Kemper
Importance: Medium

Activity

  1. Sven Fuchs
    Sven Fuchs
    • Assigned user set to Sven Fuchs

    July 8th, 2009 @ 11:33 PM

  2. Sven Fuchs
    Sven Fuchs
    • Milestone changed from 2.x to 2.3.4
    • State changed from new to open
    • Assigned user changed from Sven Fuchs to Jeremy Kemper

    Ok, here's a patch for this issue

    August 26th, 2009 @ 12:08 PM

  3. Jeremy Kemper
    Jeremy Kemper

    Hey Sven, patch doesn't apply cleanly to 2-3-stable.

    Was this already solved on master?

    August 26th, 2009 @ 05:46 PM

  4. Sven Fuchs
    Sven Fuchs

    What? Umm, sorry. No it should go into 2.3.x as well. I've been heavily juggling branches and remotes recently, so maybe I've gotten something wrong. I'll redo and resubmit the patch.

    August 26th, 2009 @ 06:11 PM

  5. Sven Fuchs
    Sven Fuchs

    Jeremy, the patch should now apply. I'll delete the first version. Sorry for the hassle.

    August 26th, 2009 @ 06:30 PM

  6. Repository
    Repository
    • State changed from open to committed

    (from [a4838ee466b18ef04d0a244bec292c1d45c4bc0f]) allow ActiveRecord#RecordInvalid exception message to be localized

    [#2754 "Validation failed" not available for translation state:committed]

    Signed-off-by: Jeremy Kemper jeremy@bitsweat.net
    http://github.com/rails/rails/commit/a4838ee466b18ef04d0a244bec292c...

    August 26th, 2009 @ 07:28 PM

  7. Repository
  8. Jeremy Kemper
    Jeremy Kemper

    Always a pleasure, Sven :)

    August 26th, 2009 @ 07:30 PM