J'ai pas ton code pour tester, mais à vu de nez :
from twisted.internet.defer import returnValue
@wamp.register(TOPICS.move)
@inlineCallback
def moveReg(self):
res = yield self.call(TOPICS.coverArea, arg1, arg2)
returnValue(res)
Car self.call est asynchrone, donc retourne un defer.
Si c'est une opération que tu fais souvent, fais toi un decorateur comme raccourcis :
def rpc(*args, **kwargs):
def decorator(func):
func = inlineCallback(func)
func = wamp.register(*args, **kwargs)(func)
return func
return decorator
rpc.return = twisted.internet.defer.returnValue
Comme ça, tu peux juste faire :
from tools import rpc
@rpc(TOPICS.move)
def moveReg(self):
res = yield self.call(TOPICS.coverArea, arg1, arg2)
rpc.return(res)