fix(i18n): repair corrupted Romanian catalog so it parses again - #41467
Conversation
ro/LC_MESSAGES/messages.po had four msgstr values ending in a stray double quote (e.g. "Indicator salvat"") and a duplicate "Color Metric" message definition. These are hard syntax errors: polib.pofile() raises on them, which broke the translation index builder, and they fail msgfmt/pybabel parsing. Remove the trailing quotes and the duplicate entry. The catalog now parses cleanly. (Strict `msgfmt --check-format` still reports pre-existing plural format-spec mismatches, the same non-fatal class already present in pl, pt_BR, zh, and zh_TW; those are left for a separate cleanup.) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Code Review Agent Run #eb2202Actionable Suggestions - 0Filtered by Review RulesBito filtered these suggestions based on rules created automatically for your feedback. Manage rules.
Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
✅ Deploy Preview for superset-docs-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #41467 +/- ##
========================================
Coverage 64.44% 64.45%
========================================
Files 2662 2663 +1
Lines 145828 145997 +169
Branches 33645 33665 +20
========================================
+ Hits 93979 94098 +119
- Misses 50147 50182 +35
- Partials 1702 1717 +15
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
SUMMARY
The Romanian catalog (
ro/LC_MESSAGES/messages.po) is corrupted onmasterwith hard syntax errors:msgstrvalues end in a stray double quote, e.g.msgstr "Indicator salvat"",msgstr[2] "Șterse %(num)d de teme"". The unescaped quote terminates the string early.msgid "Color Metric"definition (identicalmsgstr).polib.pofile()raises on the first of these, which is what broke the translation-index builder (it aborted the whole build on this one file), andmsgfmt/pybabelreject it too. This removes the four stray quotes and the duplicate entry. The catalog now parses cleanly withpoliband compiles withpybabel.Found while running the AI backfill tooling —
rowas silently excluded from every other language's translation context because it couldn't be parsed.Out of scope (intentionally): with the syntax errors gone, strict
msgfmt --check-formatnow surfaces a handful of pre-existing plural format-spec mismatches (msgstr[0]dropping the%s/%(num)dcount). That's a separate, non-fatal class already present inpl,pt_BR,zh, andzh_TW, and is left for a dedicated cleanup rather than mixed into this corruption fix.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A (translation catalog)
TESTING INSTRUCTIONS
Before, this raises
OSError: unescaped double quote found:python -c "import polib; polib.pofile('superset/translations/ro/LC_MESSAGES/messages.po')"After, it parses (4462 entries) and
pybabel compile -i superset/translations/ro/LC_MESSAGES/messages.po -o /tmp/ro.mono longer errors on syntax.ADDITIONAL INFORMATION
🤖 Generated with Claude Code