On Jun 17, 8:36 am, Tino Breddin <[email protected]> wrote:
> Yes, I did import tmpl_context but that didn't help.

I don't think importing `c` (AKA `tmpl_context`) in the controller
would solve this problem anyway.


> I also don't use c at all, the method simply renders a page.

Looking more closely at your traceback, the Pylons `render` function
assumes that `c` has been registered in the current request/thread. If
I'm reading it correctly, AuthKit calls your `render_signin` function
for you, wherein you use the Pylons render function to render your
signin template, /derived/account/signin.html. So, the first part my
first response is still applicable, but here's a different list of
possible solutions:

* Return a string instead of rendering a template
* Use Mako directly to render the template
* Register `c` manually before your call to `render` (??? never tried
this)


> I'm still trying to figure out how to do it though.
>
> Cheers
>
> On Jun 16, 3:56 am, Didip Kerabat <[email protected]> wrote:
>
> > Did you remember to import templ_context in your controllers?
>
> > E.g. from pylons import tmpl_context as c
>
> > - Didip -
>
> > On Mon, Jun 15, 2009 at 9:09 AM, Tino Breddin
> > <[email protected]>wrote:
>
> > > Hi,
>
> > > I followed the instructions given in the Pylons book [1], but when I'm
> > > trying to access a secured page the server shows an internal error
> > > with this [2] stacktrace. I'm new to Pylons and couldn't figure out
> > > what's wrong. Did anybody solve this before?
>
> > > Cheers,
> > > Tino
>
> > > [1]
> > >http://pylonsbook.com/en/1.0/simplesite-tutorial-part-3.html#styling-...
> > > [2]http://pastie.org/512635
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" 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/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to