Had a similar issue a while ago (dunno why, but I was messsing with a lot of 
packages at the time). However changing the templates to something like

<div py:if="defined('tg_flash')" .....>

did the trick.
This may be genshi specific, but maybe worth a shot.

HTH

Uwe


On Wednesday 24 October 2007, Michel Albert wrote:
> On Oct 21, 1:34 pm, Michel Albert <[EMAIL PROTECTED]> wrote:
> > Ummm... for no apparent Reason I get this error:
> >
> >   [...]
> >   File "/.../templates/master.py", line 181, in _match_func
> >     NameError: name 'tg_flash' is not defined
> >
> > I am not aware that I changed anything. At least not related to
> > tg_flash.
> >
> > The corresponding template line looks like this:
> >
> >     <div py:if="tg_flash" class="flash" py:content="tg_flash"></div>
> >
> > And here are the imports of controllers.py:
> >
> >   from model import *
> >   from turbogears import identity, redirect, widgets, paginate,
> > validate, error_handler, flash, validators, controllers, expose
> >   from cherrypy import request, response
> >   from sqlalchemy import or_, bindparam, literal
> >   from sqlalchemy.exceptions import SQLError
> >   import cherrypy, os
> >   import md5
> >   import mimetypes
> >   from datetime import datetime
> >   from tgwebservices.controllers import WebServicesRoot, wsexpose,
> > wsvalidate
> >
> > Any idea what's going on?
>
> Is there any way I can inspect what variables are available inside the
> template? Like that I could probably figure out what's going on.
>
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to