around functions and classes
E306 expected 1 blank line before a nested definition, found 0
E303 too many blank lines (3)
raise web.Finish('ok\n')
-
application = web.Application([
(r'/dummy/', DummyHandler),
(r'/dummyasync/', DummyAsyncHandler),
def run_redbot(self, url, method, body, headers):
red = HttpResource(url, method=method, req_body=body,
req_hdrs=headers)
+
def work():
red.run(thor.stop)
thor.run()
self.io_loop.add_callback(self.stop)
+
thread = threading.Thread(target=work)
thread.start()
self.wait()
app_log.error('%s: %s', context['message'],
type(context.get('exception')))
self.io_loop.asyncio_loop.set_exception_handler(exc_handler)
+
@gen.coroutine
def f():
yield gen.moment
executor.submit(lambda: time.sleep(0.01)))
-
class WaitIteratorTest(AsyncTestCase):
@gen_test
def test_empty_iterator(self):