Fixing formatting of exceptions in the console