Broken coloring when used with `tqdm`
offchan42 opened this issue · 4 comments
I see that when I do from tqdm import tqdm
and then run pp(a_variable)
There is no color for the pp()
message anymore. So my work around was to import tqdm
as late as possible. Is this problem with snoop or tqdm? How can we fix this?
This happens on Windows 10 command prompt.
tqdm Link: https://github.com/tqdm/tqdm
What happens if you uninstall colorama?
It seems like uninstalling colorama
fixes the issue. What does it mean then?
tqdm
uses colorama (if it's available) to process ANSI escape codes in Windows. Windows only recently started supporting those escape codes natively. snoop
relies on that new ability instead of colorama, which is the traditional solution to the lacking support. colorama was probably stripping the escape codes, although I'm not sure. I'm not on a Windows machine.