From 5cc3f4577f3408101e817136ceca501c526be72b Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Fri, 13 Sep 2019 01:31:46 +0200 Subject: [PATCH] Print errors to stderr MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit E.g. There was a critical error during execution of Flake8: Expected `per-file-ignores` to be a mapping from file exclude patterns to ignore codes. Configured `per-file-ignores` setting: … --- src/flake8/main/application.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/flake8/main/application.py b/src/flake8/main/application.py index 6393dad..2659ace 100644 --- a/src/flake8/main/application.py +++ b/src/flake8/main/application.py @@ -394,8 +394,8 @@ class Application(object): LOG.exception(exc) self.catastrophic_failure = True except exceptions.ExecutionError as exc: - print("There was a critical error during execution of Flake8:") - print(exc) + print("There was a critical error during execution of Flake8:", file=sys.stderr) + print(exc, file=sys.stderr) LOG.exception(exc) self.catastrophic_failure = True except exceptions.EarlyQuit: