[Zope3-checkins] CVS: Zope3/lib/python/Zope/PageTemplate - TALES.py:1.5.30.1

Marius Gedminas mgedmin@codeworks.lt
Tue, 10 Dec 2002 12:44:11 -0500


Update of /cvs-repository/Zope3/lib/python/Zope/PageTemplate
In directory cvs.zope.org:/tmp/cvs-serv13927

Modified Files:
      Tag: named-component-configuration-branch
	TALES.py 
Log Message:
Removed the overlong modules list from TALES tracebacks

=== Zope3/lib/python/Zope/PageTemplate/TALES.py 1.5 => 1.5.30.1 ===
--- Zope3/lib/python/Zope/PageTemplate/TALES.py:1.5	Fri Jun 14 17:14:19 2002
+++ Zope3/lib/python/Zope/PageTemplate/TALES.py	Tue Dec 10 12:44:10 2002
@@ -2,14 +2,14 @@
 #
 # Copyright (c) 2001, 2002 Zope Corporation and Contributors.
 # All Rights Reserved.
-# 
+#
 # This software is subject to the provisions of the Zope Public License,
 # Version 2.0 (ZPL).  A copy of the ZPL should accompany this distribution.
 # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
 # WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 # WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
 # FOR A PARTICULAR PURPOSE.
-# 
+#
 ##############################################################################
 """TALES
 
@@ -142,7 +142,7 @@
             raise CompilerError, (
                 'Unrecognized expression type "%s".' % type)
         return handler(type, expr, self)
-    
+
     def getContext(self, contexts=None, **kwcontexts):
         if contexts is not None:
             if kwcontexts:
@@ -272,10 +272,12 @@
         self.line = context.position[0]
         self.column = context.position[1]
         self.expression = repr(expression)
-        
+
     def getInfo(self, as_html=0):
         import pprint
         data = self.context.contexts.copy()
+        if 'modules' in data:
+            del data['modules']     # the list is really long and boring
         s = pprint.pformat(data)
         if not as_html:
             return '   - Names:\n      %s' % s.replace('\n', '\n      ')
@@ -295,4 +297,3 @@
         return self._name, self._expr
     def __repr__(self):
         return '<SimpleExpr %s %s>' % (self._name, `self._expr`)
-