when importing a french translation, I was confronted with the error message:

Le fichier de traduction fr.po contient une erreur : la formule de valeurs plurielles n'a pu être analysée.

which is a translation for:

The translation file fr.po contains an error: the plural formula could not be parsed.

Of course, this is mostly useless, since *all* translation files for french are named... fr.po !

The following patch replaces it with:

Le fichier de traduction sites/all/modules/imagefield/translations/fr.po contient une erreur : la formule de valeurs plurielles n'a pu être analysée.

Comments

brianV’s picture

Status: Active » Reviewed & tested by the community

I'm all for more helpful error messages.

vm’s picture

Version: 6.13 » 6.x-dev

This should be patched against Drupal 7.x I think and backported from there. It certainly won't go directly into 6.13 and thus at the very least would have to be patched against Drual 6.x-dev. As such that is where I am moving the version to, especially since we have an included patch.

mikey_p’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.61 KB

The patch applied (with large offset) to HEAD. I've updated _localte_import_parse_plural_forms() to show the difference in variable name, and in phpdoc.

mikey_p’s picture

Version: 6.x-dev » 7.x-dev

setting this so hopefully the test bot picks it up

dries’s picture

Status: Needs review » Fixed

Committed to CVS HEAD. Thanks!

mikey_p’s picture

Version: 7.x-dev » 6.x-dev
Status: Fixed » Needs review
StatusFileSize
new2 KB

Since this was originally filed against 6...

gábor hojtsy’s picture

Would be great to get some testing.

gábor hojtsy’s picture

#545652: Language files import error message need to show full path was sort of a duplicate, kept open for solving other related issues in other locale error messages.

Status: Needs review » Needs work

The last submitted patch, 522176-6.patch, failed testing.

gábor hojtsy’s picture

Component: language system » locale.module
gábor hojtsy’s picture

Patch looks generally good for what it does. However, the closing parenthesis is removed from the line at _locale_import_parse_plural_forms(). No wonder it does not pass testing :) Would be great to fix.

Status: Needs work » Closed (outdated)

Automatically closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.