Print errors to stderr

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:

        …
This commit is contained in:
Daniel Hahler 2019-09-13 01:31:46 +02:00
parent 121ea4f056
commit 5cc3f4577f

View file

@ -394,8 +394,8 @@ class Application(object):
LOG.exception(exc) LOG.exception(exc)
self.catastrophic_failure = True self.catastrophic_failure = True
except exceptions.ExecutionError as exc: except exceptions.ExecutionError as exc:
print("There was a critical error during execution of Flake8:") print("There was a critical error during execution of Flake8:", file=sys.stderr)
print(exc) print(exc, file=sys.stderr)
LOG.exception(exc) LOG.exception(exc)
self.catastrophic_failure = True self.catastrophic_failure = True
except exceptions.EarlyQuit: except exceptions.EarlyQuit: