Output file is emtpied when error reporting starts, removing any previously recorded logging
3.0.1 (mccabe: 0.5.0, pycodestyle: 2.0.0, pyflakes: 1.2.3) CPython 3.5.0 on Windows
When providing an output file argument (
--output-file) and at least one
-v for logging, the output file is emptied and any logging that occured before that is lost entirely. This makes the fact that logging is redirected to the file pretty much useless since most of it is lost.
What I suggest is to either
- not clear the file when output starts being written but when the
- not redirect logging to the output file, or
- add a
--log-fileparameter that will be the target of a
FileHandlerif provided, stdout otherwise.