svgui/pyjs/jsonrpc/web2py/jsonrpc.py
author Surkov Sergey <surkovsv93@gmail.com>
Mon, 28 Aug 2017 13:43:46 +0300
changeset 1793 c2f48d791d9f
parent 1748 ba5f64fe0e00
child 1869 49cdd843c006
permissions -rw-r--r--
fix bug with unfinished debug thread
this bug occurs when user doesn't stop debugging process in current project, and opens another project
from pyjs.jsonrpc import JSONRPCServiceBase


class JSONRPCService(JSONRPCServiceBase):

    def serve(self):
        return self.process(request.body.read())

    def __call__(self, func):
        self.methods[func.__name__] = func
        return func