-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove ANSI colors when writing to external warnings file. #11624
Remove ANSI colors when writing to external warnings file. #11624
Conversation
- warning file is automatically closed on demand. - ANSI control sequences are stripped by default.
Is the I can't imagine anyone wanting those escape sequences in their warnings file. More importantly, I think adding this option would cause confusion with the already existing |
Err.. I don't really know. Like sometimes you may want to keep the colors when you print them using some weird commands. Or for filtering. It was just to ensure that if there was someone out there doing it, then they don't need to change much (although I would recommend using |
On a second thought, I think not having that option would be the best. People that want to keep colors should simply Since I am away, I won't be able to update the PR soon. At least, it would simplify a bit the logic and reduce the number of CLI options for the end-user to remember. |
So, I removed |
# Conflicts: # sphinx/cmd/build.py # sphinx/util/console.py
I'll make the changes today or tomorrow and add a CHANGES entry as well. |
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Thanks @picnixz! |
Fix #11617.
Fix #11574.
In addition, I needed to fix #11574 so that testing can be done properly (otherwise the file descriptor is kept opened in write mode and it is not possible to correctly read it).
@AA-Turner Can you bump the development version 7.2.3 (or 7.3) so that I can add a CHANGES entry please?