Googling about it, it appears like the notebook should support ANSI colors, but I cannot get it to work.
I just want to print colored statements from within my functions.

Any idea what's wrong? The problem persists after disabling all nbextensions.

Don't use colorama.init(). Colorama is intended to turn the ANSI colour codes into Windows console API calls, but it will detect that you're not in a Windows console and strip the ANSI codes out entirely, so the notebook doesn't see them.
Great, thank you @takluyver !
Not working.
ipython==6.4.0
ipython-genutils==0.2.0
Importing tqdm affects the colors if anyone still using that thing.
@krishnachouhan why is that?
Not sure @jolespin.
Here is the opened issue..
https://github .com/tqdm/tqdm/ issues /678
Most helpful comment
Don't use
colorama.init(). Colorama is intended to turn the ANSI colour codes into Windows console API calls, but it will detect that you're not in a Windows console and strip the ANSI codes out entirely, so the notebook doesn't see them.