mirror of
https://github.com/progval/Limnoria.git
synced 2025-04-26 04:51:06 -05:00
Web: Increase timeout to 10 and improve error message.
This commit is contained in:
parent
32e3be3dac
commit
8cd0b4c1e3
@ -92,10 +92,11 @@ def fetch_sandbox(f):
|
|||||||
def newf(self, irc, *args):
|
def newf(self, irc, *args):
|
||||||
try:
|
try:
|
||||||
replies = commands.process(process, self, irc, *args,
|
replies = commands.process(process, self, irc, *args,
|
||||||
timeout=5, heap_size=1024*1024,
|
timeout=10, heap_size=1024*1024,
|
||||||
pn=self.name(), cn=f.__name__)
|
pn=self.name(), cn=f.__name__)
|
||||||
except commands.ProcessTimeoutError:
|
except commands.ProcessTimeoutError:
|
||||||
raise utils.web.Error(_('Page is too big.'))
|
raise utils.web.Error(_('Page is too big or the server took '
|
||||||
|
'too much time to answer the request.'))
|
||||||
else:
|
else:
|
||||||
for (method, args, kwargs) in replies:
|
for (method, args, kwargs) in replies:
|
||||||
getattr(irc, method)(*args, **kwargs)
|
getattr(irc, method)(*args, **kwargs)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user