[Zope3-checkins] CVS: Zope3/src/zope/app/pagetemplate - engine.py:1.28

Fred L. Drake, Jr. fred at zope.com
Thu Apr 29 12:10:03 EDT 2004


Update of /cvs-repository/Zope3/src/zope/app/pagetemplate
In directory cvs.zope.org:/tmp/cvs-serv24322

Modified Files:
	engine.py 
Log Message:
localize an import since it's only needed for a partilcular use;
zope.app.pythonpage can have zope.app.interpreter as a dependency


=== Zope3/src/zope/app/pagetemplate/engine.py 1.27 => 1.28 ===
--- Zope3/src/zope/app/pagetemplate/engine.py:1.27	Tue Apr  6 16:58:13 2004
+++ Zope3/src/zope/app/pagetemplate/engine.py	Thu Apr 29 12:10:02 2004
@@ -32,7 +32,6 @@
 
 from zope.app import zapi
 from zope.app.i18n import ZopeMessageIDFactory as _
-from zope.app.interpreter.interfaces import IInterpreter
 from zope.app.traversing.adapters import Traverser
 
 
@@ -95,6 +94,9 @@
                     'you cannot have inline code snippets in your Page '
                     'Template. Activate Inline Code Evaluation and try again.')
 
+        # XXX This is only needed when self.evaluateInlineCode is true,
+        # so should only be needed for zope.app.pythonpage.
+        from zope.app.interpreter.interfaces import IInterpreter
         interpreter = zapi.queryUtility(self.context, IInterpreter, name=lang)
         if interpreter is None:
             error = _('No interpreter named "${lang_name}" was found.')




More information about the Zope3-Checkins mailing list