Hi, i had this problem too and discovered that need to run parse_command_line()
to setup logging by default. Check the code in tornado.options:
http://github.com/facebook/tornado/blob/master/tornado/options.py#L126
Here is an example:
def main():
application = tornado.web.Application([
(r"/", MainHandler),
])
# this line will setup default logging no matter if you use command options
tornado.options.parse_command_line()
logging.info("starting torando web server")
http_server = tornado.httpserver.HTTPServer(application)
http_server.listen(8888) # hardcoded port
tornado.ioloop.IOLoop.instance().start()
Regards,
--
ø Rolando Espinoza La fuente
Attila
If someone wonders why they do not get log output, it could be cause
they pass non-option arguments to their programs.
see http://github.com/schmir/tornado/commit/f4590b4ddb93e37f3d207f6070650a3141b14ec1
for a fix. it also fixes handling of "--"