set_description does not update correctly for notebook #345
Closed
Description
I am using tqdm_notebook
and trying to update the description. Instead of updating the initial description, it leaves the original description and sticks the new one between {bar}
and {r_bar}
.
I am using it in a more manual manner like:
from time import sleep
from tqdm import tqdm_notebook
with tqdm_notebook(total=100, miniters=1, mininterval=0, desc="start") as pbar:
sleep(1) # do stuff
pbar.set_description("doing stuff")
pbar.update(10)
sleep(2)
pbar.set_description("more stuff")
pbar.update(20)
sleep(1)
pbar.set_description("refresh")
pbar.refresh()
After first update:
start: |||| doing stuff: 10% 10/100 [00:01<00:09, 9.82it/s]
After second update:
start: ||||||| more stuff: 30% 30/100 [00:03<00:07, 9.89it/s]