Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (
Help us improve Python packaging - Donate today!

Buildout recipe to extract and manage po files

Project Description


This buildout recipe creates i18n tools to extract and manage po files. More specifically, i18n messages can occur in Python code, in Chameleon (ZPT) page templates and in ZCML declarations.


This recipe provides the following scripts:


extract the i18n messages from the Python code, the Chameleon (ZPT) page templates and the ZCML configuration files;


requires the GNU gettext package to be installed; the command ‘msgmerge’ will be executed for each language;


prints a simple statistics with the status of the translations.


Add to your buildout configuration file the following snippet:

recipe = tranchitella.recipe.i18n
package = PACKAGE
zcml = PACKAGE:configure.zcml
expressions =
output = locales
domain = DOMAIN
verify_domain = true
exclude =

Replace PACKAGE with your Python package name and DOMAIN with your i18n domain; the zcml setting is optional.

0.6 (2011-06-20)

  • Do not break if the message extracted from a python file contains utf-8 text.

0.5 (2010-06-06)

  • Soft-dependency on quipu.publisher for the correct processing of ZCML files.
  • Avoid useless double new line at the end of the autogenerated POT file.
  • Avoid empty defaaults for zope.i18n’s MessageID instances.

0.4 (2010-04-15)

  • Install again on update, otherwise the i18n scripts are not updated unless they are explicitly removed.

0.3 (2010-03-17)

  • Added support for Chameleon expressions using the expressions option in buildout.cfg or the --expression command line argument.
  • Bug fix: now the po template file is correctly encoded in UTF-8.
  • Bug fix: element’s tail should not be included in the msg id.
  • Bug fix: added support for translated elements contained in other translated elements and marked with i18n:name.

0.2 (2010-03-02)

  • Added a new helper script to recompile the po files.

0.1 (2010-02-17)

  • First public release.
Release History

Release History

This version
History Node


History Node


History Node


History Node


History Node


History Node


Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
tranchitella.recipe.i18n-0.6.tar.gz (23.2 kB) Copy SHA256 Checksum SHA256 Source Jun 20, 2011

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting