diff --git a/logdna/logdna.py b/logdna/logdna.py index 47b4b19..f422da1 100644 --- a/logdna/logdna.py +++ b/logdna/logdna.py @@ -62,6 +62,7 @@ def flush(self): logger.error('Error in request to LogDNA: ' + str(e)) def emit(self, record): + msg = self.format(record) record = record.__dict__ opts = {} if 'args' in record: @@ -69,7 +70,7 @@ def emit(self, record): message = { 'hostname' : self.hostname, 'timestamp': int(time.time()), - 'line': record['msg'], + 'line': msg, 'level': record['levelname'] or self.level, 'app': self.app or record['module'] }