[ZCM] [ZC] 1491/ 6 Resolve "talgettext.py error"

Collector: Zope Bugs, Features, and Patches ... zope-coders-admin at zope.org
Thu Sep 23 01:37:56 EDT 2004


Issue #1491 Update (Resolve) "talgettext.py error"
 Status Resolved, Zope/bug low
To followup, visit:
  http://collector.zope.org/Zope/1491

==============================================================
= Resolve - Entry #6 by ajung on Sep 23, 2004 1:37 am

 Status: Accepted => Resolved


________________________________________
= Comment - Entry #5 by ajung on Sep 23, 2004 1:37 am

fixed on 2.7 branch + SVN trunk
________________________________________
= Comment - Entry #4 by heinrichbernd on Sep 7, 2004 9:29 am


Uploaded:  "talgettext.py"
 - http://collector.zope.org/Zope/1491/talgettext.py/view
I had no problems to process multiple files.

The attachment contains a change of method "translate" in class "POEngine": only a non-empty "msgid" is added to "domain"-dict. This change does no longer suppress the pot-header in case of a page-template containing e.g.
 ... tal:content="here/somevalue" i18n:translate="" ...


________________________________________
= Accept - Entry #3 by ajung on Sep 5, 2004 10:56 am

 Status: Pending => Accepted

 Supporters added: ajung

talgettext.py seems to create the header only when you process a single a file but not multiple. There is the following code


    if '' not in messages:
        print >> outfile, pot_header % {'time': time.ctime(),
                                        'version': __version__}

that seems to suppress the header in some situation.

Unfortunately I have no time to track this down in detail. I would be fine if you could track this down and submit a patch for the problem.
________________________________________
= Comment - Entry #2 by heinrichbernd on Sep 2, 2004 8:36 am

example must be:  tal:content="here/somevalue" i18n:translate=""
________________________________________
= Request - Entry #1 by heinrichbernd on Sep 2, 2004 8:25 am

when creating a pot-file from page templates containing code like:
... tal:content="here/somevalue tal:translate="" ...
the pot-file doesn't contain a valid header, which makes it difficult to create translations of this file.
==============================================================



More information about the Zope-Collector-Monitor mailing list