import string from time import time import cherrypy import uuid class Root(object): @cherrypy.expose def index(self): return 'Sup?' from button import Button cherrypy.tree.mount(Root()) cherrypy.tree.mount(Button(), '/button', { '/': {'request.dispatch': cherrypy.dispatch.MethodDispatcher()} }) cherrypy.engine.start() cherrypy.engine.block()