@ Iceberg and Anthony... Thanks a lot for stopping by.
1. return 'nothing' and 2. raise HTTP(403, errormsg) are 2 different types of returning responses again. - the requirement we got, doesn't really encourage this :( any other suggestions pls? On Jun 22, 10:08 pm, Anthony <[email protected]> wrote: > Also, anywhere in your code (e.g., in a model file), you can test to see if > the app should stop responding, and if so, raise the web2py HTTP error with > a 4xx or 5xx status code. For example: > > if delay_time_for_responding=='infinite': > raise HTTP(403) > > Seehttp://web2py.com/book/default/chapter/04#HTTP-and-redirect. > > Anthony > > > > On Wednesday, June 22, 2011 11:54:30 AM UTC-4, Iceberg wrote: > > What do you mean stop getting response? How about response with some > > "empty" stuff? Such as: > > > def index(): > > if delay_time_for_responding=='infinite': > > return 'nothing' > > ... # normal code starts here > > > Or if you really mean a response is suspended infinitely, you might > > need something called "comet". > > > Regards, > > Iceberg > > > On Jun 22, 10:36 pm, sheM <[email protected]> wrote: > > > Hi, > > > > We have an application developed using web2py. > > > > There is a requirement where we should be stopping the application > > > respond to the requests. > > > Eg: when delay_time_for_responding == 'infinite' there should be no > > > response. > > > sys.exit() or break is something that we don't want to do as web2py > > > errors out. > > > > Any way out in web2py? > > > > Sheetal. M- Hide quoted text - > > - Show quoted text -

