On Oct 13, 1:13 pm, Arturo Filastò <a...@baculo.org> wrote: > When I try to use the suggested decorator I get this error: > > Traceback (most recent call last): > File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/ > lib/python2.7/gluon/restricted.py", line 192, in restricted > exec ccode in environment > File "/xxxxx/xxxx/xxxxx/xxx/xxxx/xxxx/GlobaLeaks/globaleaks/ > applications/globaleaks/controllers/submission.py", line 317, in > <module> > File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/ > lib/python2.7/gluon/globals.py", line 145, in <lambda> > self._caller = lambda f: f() > File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/ > lib/python2.7/gluon/globals.py", line 107, in f > rest_action = _action().get(method,None) > AttributeError: 'NoneType' object has no attribute 'get' > > What could this depend on? > > I looks like an error in web2py code. >
Sorry, my fault. I forgot to do return locals(). Now it's working fine. > Is it safe to use request.restful() now? > > Or is it something still being experimented and maybe I should wait > some time before having it in productions? > These questions are still valid though. - Art.