'Start recording S3Log messages'

def listen(self):

    if (self.handler is not None):
        return
    strbuf = self.strbuf
    if (strbuf is None):
        try:
            from cStringIO import StringIO
        except:
            from StringIO import StringIO
        strbuf = StringIO()
    handler = logging.StreamHandler(strbuf)
    logger = logging.getLogger(__name__)
    logger.addHandler(handler)
    self.handler = handler
    self.strbuf = strbuf
    return
