'Configures guestfs to be verbose.'

def configure_debug(self):

    if (not self.handle):
        LOG.warning('Please    consider    to    execute    setup    before    trying    to    configure    debug    log    message.')
    else:
        def log_callback(ev, eh, buf, array):
            if (ev == guestfs.EVENT_APPLIANCE):
                buf = buf.rstrip()
            LOG.debug("event=%(event)s    eh=%(eh)d    buf='%(buf)s'    array=%(array)s", {'event': guestfs.event_to_string(ev), 'eh': eh, 'buf': buf, 'array': array})
        events = (((guestfs.EVENT_APPLIANCE | guestfs.EVENT_LIBRARY) | guestfs.EVENT_WARNING) | guestfs.EVENT_TRACE)
        self.handle.set_trace(True)
        self.handle.set_verbose(True)
        self.handle.set_event_callback(log_callback, events)
