Wrong console coloring on Win7
x-santiaga-x opened this issue · comments
x-santiaga-x commented
What's the bug all about?
An attempt to run the command on win7 results in the output of messages with color escape sequences to the console.
The same result occurs when run from VScode.
What command led to this issue?
pipupgrade --help
Logs
c:\>pipupgrade --help
usage: pipupgrade [--ignore IGNORE] [--pip-path PIP_PATH] [-y] [-c]
[skipped lines]
←[0;91mpipupgrade←[0m (v ←[0;1m1.8.4←[0m)
←[0;1mUPGRADE ALL THE PIP PACKAGES!←[0m
[skipped lines]
Python logs
Python 3.7.8 (tags/v3.7.8:4b47a5b6ba, Jun 28 2020, 08:53:46) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import os, sys
>>> os.fstat(0) == os.fstat(1)
True
>>> sys.stdout.isatty()
True