Difference between revisions of "Talk:Pootle"

From SME Server
Jump to navigationJump to search
(→‎bugs: bug numbers)
(→‎bugs: missing <base> entries)
Line 25: Line 25:
 
support & userpassword functions contain lexicons
 
support & userpassword functions contain lexicons
 
:not all translations are in /etc/e-smith/locale/, these have to be split for xml2po to find en version
 
:not all translations are in /etc/e-smith/locale/, these have to be split for xml2po to find en version
::/etc/e-smith/web/functions/support
 
::/etc/e-smith/web/panels/password/cgi-bin/userpassword
 
  
  
*possible BIG bug
+
*http://bugs.contribs.org/show_bug.cgi?id=3782#c6
http://bugs.contribs.org/show_bug.cgi?id=3782#c6
+
xml2po fails when converting back to xml if duplicate <trans> exist<br>
:xml2po fails when converting back to xml if duplicate <trans> exist
 
FM XML:
 
      <entry>
 
        <base>Online manual</base>
 
        <trans>Online manual</trans>
 
      </entry>
 
 
      <entry>
 
        <base>Test</base>
 
        <trans>Online manual</trans>
 
      </entry>
 
 
 
 
and the english <trans> values may be the same, but the translation may not
 
and the english <trans> values may be the same, but the translation may not
FM XML in fr:
 
      <entry>
 
        <base>Online manual</base>
 
        <trans>Online manual</trans>
 
      </entry>
 
 
      <entry>
 
        <base>Test</base>
 
        <trans>Le manual online</trans>
 
      </entry>
 
 
  
  
*possible bug, FIXED
+
*http://bugs.contribs.org/show_bug.cgi?id=3877
:xml2po fails creating .po if tags are not closed eg. <nowiki><p> with out </p></nowiki>
+
xml2po fails creating .po if tags are not closed
::http://bugs.contribs.org/show_bug.cgi?id=3877
 
::Fixing this problem not solve the case of the unique tag <nowiki><br></nowiki>.
 
::May be you can preprocess this tag at script level.
 
::: Yes, these can be preprocessed, others can be added if required
 
  
  
 
*http://bugs.contribs.org/show_bug.cgi?id=3879
 
*http://bugs.contribs.org/show_bug.cgi?id=3879
 
localnetworks, has no value for ROUTER_DESC
 
localnetworks, has no value for ROUTER_DESC
    <entry>
 
        <base>ROUTER_DESC</base>
 
        <trans>
 
        </trans>
 
    </entry>
 
 
ROUTER_DESC can be removed it is unused
 
# cat /etc/e-smith/web/functions/localnetworks |grep ROUTER
 
    ok  ($ua->follow("Click here"),        "ADDING NETWORK WITH DEFAULT ROUTER");
 
            <label>ROUTER</label>
 
  
  
 
*http://bugs.contribs.org/show_bug.cgi?id=3880
 
*http://bugs.contribs.org/show_bug.cgi?id=3880
 
hostentries line 300 has empty entry
 
hostentries line 300 has empty entry
    <entry>
 
        <base></base>
 
        <trans>
 
        </trans>
 
    </entry>
 
  
  
 
*http://bugs.contribs.org/show_bug.cgi?id=3881
 
*http://bugs.contribs.org/show_bug.cgi?id=3881
 
the german lexicon has a redundant translation
 
the german lexicon has a redundant translation
# slocate reinstall
 
/etc/e-smith/locale/de/etc/e-smith/web/functions/reinstall
 
 
   
 
   
# rpm -qf /etc/e-smith/locale/de/etc/e-smith/web/functions/reinstall
+
 
smeserver-locale-de-1.2.0-33.el4.sme
+
*http://bugs.contribs.org/show_bug.cgi?id=3882
 +
lexicons with addition or missing <base> entries
  
 
==Console==
 
==Console==

Revision as of 05:08, 9 February 2008

Preliminary

The Goal is to manage SME translations with Pootle hosted on contribs.org. The current method excellent as it is makes it hard to find missing strings and to easily replace them.

Test pootle site: http://www.unixlan.com.ar:8888

Once we have everything worked out how to interact with pootle and the formmagick stuff then I'll get something up on contribs.org that everyone can use. It would be really nice if we could automate the extraction/import of files that need to be translated into pootle but first things first.

Slords 18:23, 24 January 2008 (MST)

Formagick

we are using http://linux.die.net/man/1/xml2po to convert the xml lexicons to .po files and back

You can download from http://mirror.contribs.org/smeserver/contribs/nhall/sme7/contribs/pootle/rpm/gnome-doc-utils-0.12.0-1.noarch.rpm

To create .po and export xml files, we have written a few shell scripts and added a translation file smetrans.py

we'll release these later for contribs authors


bugs

support & userpassword functions contain lexicons

not all translations are in /etc/e-smith/locale/, these have to be split for xml2po to find en version


xml2po fails when converting back to xml if duplicate <trans> exist
and the english <trans> values may be the same, but the translation may not


xml2po fails creating .po if tags are not closed


localnetworks, has no value for ROUTER_DESC


hostentries line 300 has empty entry


the german lexicon has a redundant translation


lexicons with addition or missing <base> entries

Console

update all .po files

FIXED, Templates have been implemented with up to date strings, now it's over to users to translate them


.po file names are inconsistent, SV & FR add .tmpl.po

FIXED, in pootle: .tmpl.po is correct, other languages have been changed


Use UTF-8 for console .po files

Pootle has problems with the current charset=iso-8859-1
we now use UTF-8

WONTFIX, we will script the conversion back to iso-8859-1

revision control using CVS/SVN

Today I had a quick look at the pootle pages and found a wiki as well, which has some valuable information like for instance revision control using CVS/SVN: http://translate.sourceforge.net/wiki/pootle/version_control - Cactus 03:26, 25 January 2008 (MST)

A few links for future implementation:

http://subversion.tigris.org/tools_contrib.html#po_update_sh
http://subversion.tigris.org/tools_contrib.html#verify_po_py
http://subversion.tigris.org/tools_contrib.html#svnmerge_py
http://subversion.tigris.org/tools_contrib.html#svnmerge_sh

Remarks

Translation Workflow

Draft suggestions ...

.po files

  • gettext strings are in various files in cvs, currently we think we have them all in pootle as .pot template files
we need to use xgettext to search a maintained list of files to extract current gettext strings
this may find missing, or modified strings or remove old strings saving on pointless translations
  • existing translations have been placed in pootle and merged with the templates
this shows missing translations very nicely and is ready for user testing
  • all .po files have been converted to UTF-8, they will be converted back to ISO-8859-1 when patching SME
  • changes to original files, ie changed gettext strings, have to be tracked as usual in the bug tracker
these are imported into the templates, other languages are updated from templates
  • at some point we diff against cvs po files, the patch is checked and applied.

FormMagick files

  • these are XML files with a <base> and <trans> pair of strings, these can be converted to .po files with some work
  • some rough scripts are being worked on above, there may be others on the net waiting to be found...
we need to clean up some inconsistencies in the english lexicons and they will be our .pot templates
we need to script the conversion of existing translations into .po files
  • changes to original files, have to be tracked as usual in the bug tracker
the following is speculative ...
these are imported into the .pot templates, other languages are updated from templates
new <base> strings only have to be added to the cvs xml file for english
  • at some point we script xml2po to apply the new translation back to the xml file,

then diff against cvs, make patch, check and apply

Pootle Usage

Test pootle site: http://www.unixlan.com.ar:8888

untranslated words

click "Show Editing Functions" and finally at "Quick Translate" for each file or whole language.

Also you can see the suggestions clicking at "Review Suggestions".

checks

click "show checks" to see a list of syntax errors

acronyms  6 strings (2%) failed
brackets 17 strings (6%) failed
doublequoting 4 strings (1%) failed
doublespacing 1 string (0%) failed
endpunc 11 strings (3%) failed
endwhitespace 4 strings (1%) failed
numbers 2 strings (0%) failed
puncspacing 2 strings (0%) failed
sentencecount 2 strings (0%) failed
simplecaps 16 strings (5%) failed
startcaps 6 strings (2%) failed
unchanged 7 strings (2%) failed
untranslated 53 strings (19%) failed

click on one of the links offered and fix them

See http://translate.sourceforge.net/wiki/guide/pofilter_examples and http://translate.sourceforge.net/wiki/guide/translation/commonerrors

Merging new strings

Add, remove or modify strings in the template/*.pot file then click 'update from template'.

New strings are added
modified strings use existing data and made fuzzy (i think)
deleted strings are moved to the bottom of the file and commented out with #~