Skip to content

docs: describe the per-xblock translation extraction - #90

Draft
farhan wants to merge 3 commits into
mainfrom
farhan/update-translation-docs
Draft

farhan wants to merge 3 commits into
mainfrom
farhan/update-translation-docs

Conversation

@farhan

@farhan farhan commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Ticket: openedx/xblocks-core#241

Follow-up to #35, which changed make extract_translations to write one django.po per XBlock but left the docs describing the old combined catalog. Same doc updates as openedx/xblocks-core#329.

Summary

  • README.md and docs/how-tos/internationalization.rst: describe the per-XBlock output at <module_name>/conf/locale/en/LC_MESSAGES/django.po, and the translations/xblocks-extra/<module_name>/conf/locale/ layout in openedx-translations. Remove the text.po, combined-catalog, compile, dummy, validate and Transifex CLI sections, since those targets no longer exist.
  • Makefile: remove the unused COMBINED_LOCALE_DIR and a stray space before the tab on the mv line.
  • Makefile: extract_translations now stops and exits non-zero if any block fails (same fix as build: extract translations per xblock for openedx-translations xblocks-core#329), so the daily openedx-translations job can't commit a partial set of source files.
  • src/freetextresponse/conf/locale/config.yaml: remove dummy_locales, since nothing reads it now.

How to test

  1. uv run --with edx-i18n-tools make extract_translations (needs GNU gettext)
  2. Confirm 7 files: <module_name>/conf/locale/en/LC_MESSAGES/django.po

Local result: same msgid counts as on main for all 7 XBlocks.

🤖 Generated with Claude Code

farhan and others added 2 commits November 16, 2026 15:04
COMBINED_LOCALE_DIR and freetextresponse's dummy_locales are no longer
read now that only extract_translations remains. Also drop a stray
leading space before the tab on the mv line.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The README and i18n how-to still described the combined text.po
catalog and the removed compile, dummy and Transifex targets.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@codecov

codecov Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.68%. Comparing base (7ecabf8) to head (98f8623).

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #90   +/-   ##
=======================================
  Coverage   82.68%   82.68%           
=======================================
  Files          48       48           
  Lines        1461     1461           
  Branches      117      117           
=======================================
  Hits         1208     1208           
  Misses        220      220           
  Partials       33       33           
Flag Coverage Δ
unittests 82.68% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

The loop ran as one shell command whose exit code came from its last
statement, so a failed i18n_tool, msgcat or mv was swallowed and make
exited 0. The daily openedx-translations job could then commit a
partial set of source files. Run the loop under set -e, with each
step as its own statement so set -e catches it. Same fix as
openedx/xblocks-core#329.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant