#๐ Coloring incorrect results in TQDM as red like as bad sectors on disks.
19 messages ยท Page 1 of 1 (latest)
@bright night
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
you need a proof of concept of what you want to do
An example?
an error is considered anything that can be resolved as False
"if not result", my wording isn't very nice ik
I could make it an optional feature, like tqdm(mark_errors=False) (default to False)
then you dont need to make anything, just iterate over your data and do the writing to the screen manually
from tqdm.auto import tqdm, trange
from time import sleep
bar = trange(10)
for i in bar:
# Print using tqdm class method .write()
sleep(0.1)
if not (i % 3):
tqdm.write("Done task %i" % i)
# Can also use bar.write()
but that doesn't affect the bar's color?
I mean something like this
where red are incorrect results and green are the correct
nevermind, I thought why it's not possible, at least, not possible and visually correct
I think we can close the help page
!close
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.