Prints debug information to file.