Can you show us the traceback. It should work. On Mar 1, 3:40 am, mdmcginn <michael.d.mcgin...@gmail.com> wrote: > The Polls application (fromhttp://wiki.web2py.com/Polls_Tutorial) > doesn't work in GAE, though I can't read the tickets. The controller > seems to be okay, but not the view (detail and results.html). > > Controller: > def results(): > p = db.poll[request.args(0)] > if not p: raise HTTP(404) > return dict(poll=p) > > View (results.html): > {{extend 'layout.html'}} > <h1>{{=poll.question }}</h1> > <ul> > {{ for choice in poll.choice.select(): }} > <li>{{=choice.choice }} -- {{=choice.votes }} vote{{if > choice.votes!=1:}}s{{pass}}</li> > {{ pass }} > </ul> > > I can get around the error if I hard-code the ids in the controller > and remove the "for...pass" in the view: > > def results(): > p = db.poll[67] > c = db.choice[69] > if not p: raise HTTP(404) > return dict(poll=p,choice=c)
-- You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/web2py?hl=en.