Conversation
| self.cli_ctx.only_show_errors = True | ||
| return 1 | ||
| if CLILogging.DEBUG_FLAG in args: | ||
| self.cli_ctx.only_show_errors = False |
There was a problem hiding this comment.
self.cli_ctx.only_show_errors = False [](start = 12, length = 37)
It seems not necessary, I think by default it is false
There was a problem hiding this comment.
This line is to make sure the config is overridden by --debug. If the config is only_show_errors=True, --debug will revert it to False.
There was a problem hiding this comment.
I see you has check debug cannot be set while only_show_errors set
In reply to: 394914515 [](ancestors = 394914515)
There was a problem hiding this comment.
The check at L136 is only to check the argument --only-show-errors. It doesn't raise error when the config has the only_show_errors=True. In this case, self.cli_ctx.only_show_errors is reverted by the --debug argument.
| self.cli_ctx.only_show_errors = False | ||
| return 3 | ||
| if self.cli_ctx.only_show_errors: | ||
| return 1 |
There was a problem hiding this comment.
is this code possible reached, I think it already return 1 in ( if CLILogging.ONLY_SHOW_ERRORS_FLAG in args )
There was a problem hiding this comment.
This takes effect when no explicit --verbose, --debug or --only-show-warnings is given, but only_show_errors is specified in the config. You may refer to tests/test_log.py for a enumeration of possible scenarios.
This PR includes changes from these PRs:
--only-show-errors(Support --only-show-errors #179)