From fred at zope.com Tue Jul 13 14:15:06 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL/tests/input - test36.html:1.1.2.1 Message-ID: <20040713181506.8FE2F203107@mail.zope.org> Update of /cvs-repository/Packages/TAL/tests/input In directory cvs.zope.org:/tmp/cvs-serv15306/lib/python/TAL/tests/input Added Files: Tag: Zope-2_7-branch test36.html Log Message: Fix for issue 233 in the Zope 3 collector. This corresponds to the Hotfix_2004-07-13 product. === Added File Packages/TAL/tests/input/test36.html === some text From fred at zope.com Tue Jul 13 14:15:06 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL/tests/output - test36.html:1.1.2.1 Message-ID: <20040713181506.B6BEC20310B@mail.zope.org> Update of /cvs-repository/Packages/TAL/tests/output In directory cvs.zope.org:/tmp/cvs-serv15306/lib/python/TAL/tests/output Added Files: Tag: Zope-2_7-branch test36.html Log Message: Fix for issue 233 in the Zope 3 collector. This corresponds to the Hotfix_2004-07-13 product. === Added File Packages/TAL/tests/output/test36.html === <foo> <foo> some text From fred at zope.com Tue Jul 13 14:15:35 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Products/PageTemplates/tests/output - CheckI18nTranslateHooked.html:1.4.12.1 Message-ID: <20040713181535.B7121203106@mail.zope.org> Update of /cvs-repository/Products/PageTemplates/tests/output In directory cvs.zope.org:/tmp/cvs-serv15306/lib/python/Products/PageTemplates/tests/output Modified Files: Tag: Zope-2_7-branch CheckI18nTranslateHooked.html Log Message: Fix for issue 233 in the Zope 3 collector. This corresponds to the Hotfix_2004-07-13 product. === Products/PageTemplates/tests/output/CheckI18nTranslateHooked.html 1.4 => 1.4.12.1 === --- Products/PageTemplates/tests/output/CheckI18nTranslateHooked.html:1.4 Thu Jan 30 13:18:42 2003 +++ Products/PageTemplates/tests/output/CheckI18nTranslateHooked.html Tue Jul 13 14:15:05 2004 @@ -4,7 +4,7 @@

[foo](bar/{})

link

[dom](${name} was born in ${country}./{'country':'Antarctica','name':'Lomax'})

-

[default](hmm/{'age':25})

+

[default](hmm/{'age':'25'})

From fred at zope.com Tue Jul 13 14:15:36 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL - TALDefs.py:1.36.4.1 TALGenerator.py:1.63.4.7 TALInterpreter.py:1.78.4.6 Message-ID: <20040713181536.0A1E8203106@mail.zope.org> Update of /cvs-repository/Packages/TAL In directory cvs.zope.org:/tmp/cvs-serv15306/lib/python/TAL Modified Files: Tag: Zope-2_7-branch TALDefs.py TALGenerator.py TALInterpreter.py Log Message: Fix for issue 233 in the Zope 3 collector. This corresponds to the Hotfix_2004-07-13 product. === Packages/TAL/TALDefs.py 1.36 => 1.36.4.1 === --- Packages/TAL/TALDefs.py:1.36 Mon Apr 7 13:38:27 2003 +++ Packages/TAL/TALDefs.py Tue Jul 13 14:15:05 2004 @@ -19,7 +19,7 @@ from ITALES import ITALESErrorInfo -TAL_VERSION = "1.4" +TAL_VERSION = "1.5" XML_NS = "http://www.w3.org/XML/1998/namespace" # URI for XML namespace XMLNS_NS = "http://www.w3.org/2000/xmlns/" # URI for XML NS declarations === Packages/TAL/TALGenerator.py 1.63.4.6 => 1.63.4.7 === --- Packages/TAL/TALGenerator.py:1.63.4.6 Sun Sep 14 10:59:15 2003 +++ Packages/TAL/TALGenerator.py Tue Jul 13 14:15:05 2004 @@ -352,9 +352,8 @@ assert action == I18N_EXPRESSION key, expr = parseSubstitution(expression) cexpr = self.compileExpression(expr) - # XXX Would key be anything but 'text' or None? - assert key in ('text', None) - self.emit('i18nVariable', varname, program, cexpr) + self.emit('i18nVariable', + varname, program, cexpr, int(key == "structure")) def emitTranslation(self, msgid, i18ndata): program = self.popProgram() @@ -784,7 +783,8 @@ # - I18N_CONTENT for tal:content # - I18N_EXPRESSION for explicit tal:replace # o varname[2] will be None for the first two actions and the - # replacement tal expression for the third action. + # replacement tal expression for the third action. This + # can include a 'text' or 'structure' indicator. assert (varname[1] in [I18N_REPLACE, I18N_CONTENT, I18N_EXPRESSION]) self.emitI18nVariable(varname) === Packages/TAL/TALInterpreter.py 1.78.4.5 => 1.78.4.6 === --- Packages/TAL/TALInterpreter.py:1.78.4.5 Thu Dec 11 12:25:37 2003 +++ Packages/TAL/TALInterpreter.py Tue Jul 13 14:15:05 2004 @@ -14,7 +14,7 @@ """ Interpreter for a pre-compiled TAL program. """ - +import cgi import sys import getopt import re @@ -496,7 +496,7 @@ bytecode_handlers["insertText"] = do_insertText def do_i18nVariable(self, stuff): - varname, program, expression = stuff + varname, program, expression, structure = stuff if expression is None: # The value is implicitly the contents of this tag, so we have to # evaluate the mini-program to get the value of the variable. @@ -510,7 +510,14 @@ else: # Evaluate the value to be associated with the variable in the # i18n interpolation dictionary. - value = self.engine.evaluate(expression) + if structure: + value = self.engine.evaluateStructure(expression) + else: + value = self.engine.evaluate(expression) + + if not structure: + value = cgi.escape(str(value)) + # Either the i18n:name tag is nested inside an i18n:translate in which # case the last item on the stack has the i18n dictionary and string # representation, or the i18n:name and i18n:translate attributes are From fred at zope.com Tue Jul 13 14:15:36 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL/tests - test_htmltalparser.py:1.32.2.3 test_talinterpreter.py:1.6.12.4 Message-ID: <20040713181536.5F433203106@mail.zope.org> Update of /cvs-repository/Packages/TAL/tests In directory cvs.zope.org:/tmp/cvs-serv15306/lib/python/TAL/tests Modified Files: Tag: Zope-2_7-branch test_htmltalparser.py test_talinterpreter.py Log Message: Fix for issue 233 in the Zope 3 collector. This corresponds to the Hotfix_2004-07-13 product. === Packages/TAL/tests/test_htmltalparser.py 1.32.2.2 => 1.32.2.3 === --- Packages/TAL/tests/test_htmltalparser.py:1.32.2.2 Fri Aug 15 10:14:40 2003 +++ Packages/TAL/tests/test_htmltalparser.py Tue Jul 13 14:15:05 2004 @@ -594,7 +594,8 @@ ('span', [('tal:replace', 'str:Lomax', 'tal'), ('i18n:name', 'name', 'i18n')]))], - '$str:Lomax$')), + '$str:Lomax$', + 0)), ('rawtextBeginScope', (' was born in\n ', 2, @@ -607,7 +608,8 @@ ('span', [('tal:replace', 'str:Antarctica', 'tal'), ('i18n:name', 'country', 'i18n')]))], - '$str:Antarctica$')), + '$str:Antarctica$', + 0)), ('endScope', ()), ('rawtextColumn', ('.\n', 0))])), ('endScope', ()), @@ -638,7 +640,8 @@ ('', [('insertText', ('$bar$', []))])), ('rawtextOffset', ('
', 7))], - None)), + None, + 0)), ('endScope', ()), ('rawtextOffset', ('.', 1))])), ('endScope', ()), @@ -662,12 +665,12 @@ [('rawtextBeginScope', ('\n ', 2, (2, 2), 0, {'i18n:name': 'name'})), ('i18nVariable', ('name', - [('rawtextOffset', ('Jim', 10))], None)), + [('rawtextOffset', ('Jim', 10))], None, 0)), ('rawtextBeginScope', (' was born in\n ', 2, (3, 2), 1, {'i18n:name': 'country'})), ('i18nVariable', ('country', - [('rawtextOffset', ('the USA', 7))], None)), + [('rawtextOffset', ('the USA', 7))], None, 0)), ('endScope', ()), ('rawtextColumn', ('.\n', 0))])), ('endScope', ()), @@ -782,7 +785,7 @@ [('i18n:data', 'here/currentTime', 'i18n'), ('i18n:translate', 'timefmt', 'i18n'), ('i18n:name', 'time', 'i18n')])), - ('i18nVariable', ('time', [], None))], + ('i18nVariable', ('time', [], None, 0))], '$here/currentTime$')), ('endScope', ()), ('rawtextOffset', ('... beep!', 9))])), @@ -816,7 +819,8 @@ ('i18n:name', 'jobnum', 'i18n')])), ('rawtextOffset', ('NN', 2)), ('rawtextOffset', ('
', 7))], - '$context/@@object_name$')), + '$context/@@object_name$', + 0)), ('endScope', ())])), ('endScope', ()), ('rawtextColumn', ('
\n', 0)) @@ -860,7 +864,8 @@ [('rawtextOffset', ('user@host.com', 13))])), ('endScope', ()), ('rawtextOffset', ('', 4))], - None)), + None, + 0)), ('endScope', ()), ('rawtextColumn', ('\n', 0))])), ('endScope', ()), @@ -900,7 +905,8 @@ ('$request/submitter$', [('rawtextOffset', ('user@host.com', 13))])), ('rawtextOffset', ('', 4))], - None)), + None, + 0)), ('endScope', ()), ('rawtextColumn', ('\n', 0))])), ('endScope', ()), === Packages/TAL/tests/test_talinterpreter.py 1.6.12.3 => 1.6.12.4 === --- Packages/TAL/tests/test_talinterpreter.py:1.6.12.3 Wed Oct 1 13:14:57 2003 +++ Packages/TAL/tests/test_talinterpreter.py Tue Jul 13 14:15:05 2004 @@ -94,7 +94,7 @@ '
THIS IS TEXT FOR BARVALUE.
\n') def test_translate_static_text_as_dynamic_from_bytecode(self): - program = [('version', '1.4'), + program = [('version', '1.5'), ('mode', 'html'), ('setPosition', (1, 0)), ('beginScope', {'i18n:translate': ''}), @@ -116,7 +116,8 @@ ('', [('insertText', ('$bar$', []))])), ('rawtextOffset', ('', 7))], - None)), + None, + 0)), ('endScope', ()), ('rawtextOffset', ('.', 1))])), ('endScope', ()), From fred at zope.com Wed Jul 14 16:38:34 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL - HTMLParser.py:NONE Message-ID: <20040714203834.D55CB2030A6@mail.zope.org> Update of /cvs-repository/Packages/TAL In directory cvs.zope.org:/tmp/cvs-serv16319/lib/python/TAL Removed Files: Tag: Zope-2_7-branch HTMLParser.py Log Message: remove local version of the HTMLParser module; this is now part of Python === Removed File Packages/TAL/HTMLParser.py === From fred at zope.com Wed Jul 14 16:38:35 2004 From: fred at zope.com (Fred L. Drake, Jr.) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] CVS: Packages/TAL/tests - test_htmlparser.py:NONE Message-ID: <20040714203835.705F02030A6@mail.zope.org> Update of /cvs-repository/Packages/TAL/tests In directory cvs.zope.org:/tmp/cvs-serv16319/lib/python/TAL/tests Removed Files: Tag: Zope-2_7-branch test_htmlparser.py Log Message: remove local version of the HTMLParser module; this is now part of Python === Removed File Packages/TAL/tests/test_htmlparser.py === From fmnvhbs at expanets.com Sat Jul 17 06:46:31 2004 From: fmnvhbs at expanets.com (Virginia Dutton) Date: Sun Aug 10 17:05:20 2008 Subject: [ZPT-CVS] get smart_get debt free Message-ID: An HTML attachment was scrubbed... URL: http://mail.zope.org/pipermail/zpt-cvs/attachments/20040717/f0d53f39/attachment.html