You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Python 3.13, we added colour output to the new REPL, tracebacks and doctest, that can also be controlled with the PYTHON_COLORS, NO_COLOR and FORCE_COLOR environment variables:
Please see #127060. For the new REPL, ANSI sequences are added to the output stream only on non-Windows systems. A GUI-based program like IDLE could learn to intercept the codes and converted to GUI-specific manipulations of the text widget. But on Windows, the console is manipulated directly, and GUI-based programs are left in the dust. I think there should first be a option to get output streams consistent across systems, with or without color codes, before extending this behavior to more output.
@terryjreedy I don't quite follow, are you saying that there's no colour support for GUIs such as IDLE on Windows, and that we shouldn't add more colour handling until we can add colour for IDLE on Windows?
If so, I don't think adding colour to unittest needs to wait, as running unittest from IDLE seems somewhat of an edge case.
also, I'm not sure about the connection to #127060, that's a Linux-only bug (and when using a custom sys.excepthook).
Feature or enhancement
In Python 3.13, we added colour output to the new REPL, tracebacks and doctest, that can also be controlled with the
PYTHON_COLORS
,NO_COLOR
andFORCE_COLOR
environment variables:Let's add colour to unittest output.
Linked PRs
The text was updated successfully, but these errors were encountered: