tqdm_notebook leave=False Leaves Whitespace Behind

Created on 15 Nov 2017  路  2Comments  路  Source: tqdm/tqdm

python 3.6.3

ipykernel (4.6.1)
ipython (6.2.1)
jupyter (1.0.0)
jupyter-client (5.1.0)
jupyter-console (5.2.0)
jupyter-core (4.4.0)
tqdm (4.19.4)

All installed by pip3 on macOS 10.13.1 and Chrome 62.0.3202.94 (Official Build) (64-bit)

I am seeing extra spaces added on redrawing nested progress meters. The inner meters slowly creep farther from the top bar. Here is a quick script that demonstrates the problem:

import tqdm

address_space = set()

for i in tqdm.tqdm_notebook(range(256), desc='First Octet'):
    for j in tqdm.tqdm_notebook(range(256), desc='Second Octet', leave=False):
        for k in range(256):
            for l in range(256):
                address_space.add('{}.{}.{}.{}'.format(i, j, k, l))

If you substitute the third and fourth nested range(256) with more tqdm, the problem is even more obvious.

I have attached an animated GIF of the problem.

tqdm

duplicate 馃棎 submodule-notebook 馃摀

Most helpful comment

Appears also with Windows, appears also in Firefox.

All 2 comments

wait this is #433

Appears also with Windows, appears also in Firefox.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

CrazyPython picture CrazyPython  路  5Comments

techkang picture techkang  路  4Comments

yarikoptic picture yarikoptic  路  3Comments

casperdcl picture casperdcl  路  5Comments

jlumpe picture jlumpe  路  5Comments