The Damned Lies web application provides translation statistics about the GNOME project and many more:
- based on the Django web Framework
- provides many statistics (updated to each commit)
- offers a review workflow with different roles (translator, reviewer, committer and administrator)
- handles many VCS/DVCS (cvs, svn, git, mercurial, bzr)
- organized around teams and languages
- sends mails to the different team mailing lists
- provides RSS feeds of actions (Vertimus) for each language and team
- OpenID and local authentication
- detects string freeze breaks
Damned Lies is running at https://l10n.gnome.org
The XML interface is deprecated and replaced with the REST API on https://l10n.gnome.org/api/v1/ (currently still beta as of January 11th, 2019).
List of teams
List of modules
REST API (archived modules are filtered out in this list):
List of releases
Release stats for a locale
Contains both ui and documentation stats (see domain)
https://l10n.gnome.org/api/v1/releases/<release_name>/stats https://l10n.gnome.org/api/v1/releases/<release_name>/languages/<locale> https://l10n.gnome.org/api/v1/modules/<module_name>/branches/<branch_name>/domains/<domain_name>/languages/<locale>
Services using these APIs
In cases of API changes, it might be good to know services depending on these URIs.
Stats Generator http://fsa-bg.org/project/gtp/browser/scripts/xml-stats Alexander Shopov <email@example.com>
<put your project/name here>
Traditional GNOME applications generally store translations in a per-domain directory, with files named after the pattern <lang>.po. French is po/fr.po, German po/de.po, etc.
On the contrary, Django applications store translations in per-language directories: locale/<lang>/LC_MESSAGES/django.po
The approach taken by Damned Lies is to favour the familiar workflow of GNOME translators and create the /po directory. This also has the advantage of not requiring special development in Damned Lies. Here are the needed steps to reconcile this scheme with the Django app requirements:
To update the translations with latest strings, a management command (update-trans) has to be run, which does the following:
Copy po/<lang>.po in locale/<lang>/LC_MESSAGES/django.po
- Create a specific file containing database-based strings which need to be translated (so as all translations are done through po files)
- Run the Django traditional makemessages command to update (extract and merge) po file
Copy back locale/<lang>/LC_MESSAGES/django.po to po/<lang>.po
Note that the procedure is instance-specific due to database strings extraction.
To install the translations, another management command (compile-trans) has to be run:
Copy all po/<lang>.po files to locale/<lang>/LC_MESSAGES/django.po
- Run the compilemessages Django command to create mo files
The Django app needs to be restarted after new mo files have been installed.
There is currently no django-js domain for Damned Lies, but we could imagine a similar procedure (with a new domain, po files being stored in po-js/<lang>.po). The main downside of this strategy (for other apps than DL itself) is that it requires a running local instance of the app (due to management commands) to create the updated pot file. We could however imagine that Damned Lies calls a remote URL that produces an updated pot file, which would mean transforming the update-trans management command in a Django view (remotely callable by URL).