def run(self): try: server = socket.socket() server.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) server.bind(('127.0.0.1', self.port)) server.listen(50) wsgi_server(server, self) except GreenletExit: pass
def run(self): try: host = self.context.config.pubsubhubbub_client.host port = int(self.context.config.pubsubhubbub_client.port) log.info("WSGISubClient starting on %s:%d" % (host, port)) server = socket.socket() server.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) server.bind((host, port)) server.listen(50) wsgi_server(server, self) except GreenletExit: pass except: log.error("Unexpected error running WSGISubClient: %s" % traceback.format_exc())