Yeah I have mine in routes.py also I will try your suggestion and report back, thanks.
On Sat, Apr 14, 2012 at 4:33 PM, howesc <how...@umich.edu> wrote: > CAVEAT: i'm using routes.py NOT router.py.....not sure if that changes the > syntax.... > > the following is what i have to direct all errors to a user friendly page: > > routes_onerror = [ > ('<appname>/*', '/<appname>/home/missing.html'), > ] > > and in controller home.py i have a function missing(). :) > > > On Saturday, April 14, 2012 4:04:30 PM UTC-7, Bruce Wade wrote: >> >> I have been finding most of the book samples don't have enough >> information to actually implement what the second talks about. >> >> For example where/how do I implement routes_onerror >> routes_onerror = dict(application='error', controller='default', >> function='index') >> >> ERROR:Rocket.Errors.Thread-3:**Traceback (most recent call last): >> >> File >> "/home/bruce/Development/**bossteam_dev/projects/yaw/**gluon/rocket.py", >> line 1302, in run >> self.run_app(conn) >> >> File >> "/home/bruce/Development/**bossteam_dev/projects/yaw/**gluon/rocket.py", >> line 1994, in run_app >> output = self.app(environ, self.start_response) >> >> File "/home/bruce/Development/**bossteam_dev/projects/yaw/**gluon/main.py", >> line 678, in app_with_logging >> ret[0] = wsgiapp(environ, responder2) >> >> File "/home/bruce/Development/**bossteam_dev/projects/yaw/**gluon/main.py", >> line 602, in wsgibase >> http_response, request, environ, ticket) >> >> File >> "/home/bruce/Development/**bossteam_dev/projects/yaw/**gluon/rewrite.py", >> line 170, in try_rewrite_on_error >> for (key,uri) in thread.routes.routes_onerror: >> >> ValueError: too many values to unpack >> >> On Sat, Apr 14, 2012 at 1:28 PM, Anthony <abasta...@gmail.com> wrote: >> >>> One option might be to have routes_onerror (http://web2py.com/books/** >>> default/chapter/29/4#Routes-**on-error<http://web2py.com/books/default/chapter/29/4#Routes-on-error>) >>> route to a dynamic error handler, which could then send an email (in >>> addition to presenting a friendly error message). Another option might be >>> to set up a background task to watch for new tickets in the errors folder >>> and send an email whenever one appears (http://web2py.com/books/** >>> default/chapter/29/4#Running-**tasks-in-the-background<http://web2py.com/books/default/chapter/29/4#Running-tasks-in-the-background> >>> ). >>> >>> Anthony >>> >>> >>> On Saturday, April 14, 2012 4:19:06 PM UTC-4, Bruce Wade wrote: >>>> >>>> Hi, >>>> >>>> Is there an easy to way to have an email sent to me whenever a ticket >>>> is generated? >>>> >>>> -- >>>> -- >>>> Regards, >>>> Bruce Wade >>>> http://ca.linkedin.com/in/**bruc**elwade<http://ca.linkedin.com/in/brucelwade> >>>> http://www.wadecybertech.com >>>> http://www.fittraineronline.**co**m <http://www.fittraineronline.com>- >>>> Fitness Personal Trainers Online >>>> http://www.warplydesigned.com >>>> >>>> >> >> >> -- >> -- >> Regards, >> Bruce Wade >> http://ca.linkedin.com/in/**brucelwade<http://ca.linkedin.com/in/brucelwade> >> http://www.wadecybertech.com >> http://www.fittraineronline.**com <http://www.fittraineronline.com> - >> Fitness Personal Trainers Online >> http://www.warplydesigned.com >> >> -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com