added log_shorthand so the log file does not remain open in permanence, And reordered includes