def log_message(self, fmt, *args):  # pylint: disable=g-bad-name
    # Sample log output: I0313 14:23:49.512168 hostname adb logcat
    now = datetime.datetime.now()
    timestamp = now.strftime('I%m%d %T') + ('.%06d' % now.microsecond)
    # Just keep up to the first two elements of the domain name.
    hostname = '.'.join(self.address_string().split('.', 2)[:2])
    print >>sys.stderr, '%s %s - %s' % (timestamp, hostname, fmt % args)
Logs to stderr.
dataset/ETHPy150Open google/lab_device_proxy/lab_device_proxy_server.py/LabDeviceProxyRequestHandler.log_message