Delgan
Delgan
This reminds me of [the PEP 597 proposal](https://discuss.python.org/t/pep-597-use-utf-8-for-default-text-file-encoding/1819) where problem with `setup.py` and utf8 is discussed: > For example, `long_description = open("README.md").read()` in `setup.py` is a common mistake. If there...
Hi! Out of curiosity, is there any reason for implementing this using WinAPI and not simply checking for the `"TERM"` environment variable?
@SSE4 Thanks for answering! I agree checking for `"TERM"` is probably not as reliable as your solution. This is what is used by `pytest` though: [`terminalwriter.py#L36`](https://github.com/pytest-dev/pytest/blob/0f79fc6dbbe521e0fd194124bce7d0bad4ffaa2b/src/_pytest/_io/terminalwriter.py#L36). However it can become...
Hey @tartley, I just updated the PR by adding unit tests (and slightly modifying the implementation to make it more readable). Please let me know what you think of it!
Thanks for the explanation @wiggin15, this is indeed what I understood while reading the code. About the fix, as you and @SeaHOH suggested, I guess it's more explicit to skip...
What if user wants to `init()` colorama with `autoreset=True` while the stream has already been wrapped by a library with `autoreset=False`? It looks like this implementation is going to prevent...
Yeah, you are probably right and your example is pretty convincible. 🙂 The fact that several people have reported encountering `RecursionError` problems is also a hint that something could be...
Hi. Shouldn't the caller be in charge of protecting and synchronizing concurrent write rather than incorporate it into `colorama`? Is the atomicity of `print()` "officially" documented somewhere?
@barabanus I guess you can manually wrap `stdout` if you need to. ```python from colorama import AnsiToWin32 sys.stdout = AnsiToWin32(sys.stdout, convert=True, strip=False, autoreset=False).stream ```
Hey @1138-4EB. :) Could this be because I'm using the full "MINGW" emulator, while you are using the minimalist "MSYS"? I'm not sure of why your `git-bash.exe` and mine are...