Merge pull request #8239 from timoxley/patch-1

Mention `--ansi never` in `--no-ansi` deprecation
This commit is contained in:
Anca Iordache 2021-04-06 19:04:25 +01:00 committed by GitHub
commit c81046aac0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -171,7 +171,8 @@ def dispatch():
if options.get("--no-ansi"):
if options.get("--ansi"):
raise UserError("--no-ansi and --ansi cannot be combined.")
log.warning('--no-ansi option is deprecated and will be removed in future versions.')
log.warning('--no-ansi option is deprecated and will be removed in future versions. '
'Use `--ansi never` instead.')
ansi_mode = AnsiMode.NEVER
setup_console_handler(console_handler,