Skip to main content

tqdm-overflow

A tqdm progress bar that is... well, more fun.

demo

It hits 100% long before the loop is done, and then the rest of the work just pours out the end of the bar and piles up at the bottom of your terminal as sand.

Install

uv add tqdm-overflow

Use

Like tqdm, with one extra knob:

from tqdm_overflow import OverflowBar

for item in OverflowBar(range(1000), total=1000, fill_at=0.2):
    do_work(item)

fill_at is the fraction of total where the bar reads 100% (default 0.2). Everything past that overflows. You still feed it the real total and never go over it — the bar just gets there early.

There's also grains_per_unit, spawn_cap, and steps_per_frame if you want a heavier pour or faster sand.

To play with the physics or the colors, build a SandEngine or Screen and pass it in — the bar sizes them to your terminal at run time:

from tqdm_overflow import OverflowBar, SandEngine, Screen

OverflowBar(
    range(1000), total=1000, fill_at=0.2,
    engine=SandEngine(jitter=0.7, g=0.3),
    screen=Screen(palette=[(255, 80, 80), (180, 40, 40), (90, 20, 20)]),
)

Or just watch it:

tqdm-overflow
tqdm-overflow --fill-at 0.05 --delay 0.004

Needs

Python 3.10+, and a terminal that does truecolor and braille — kitty, alacritty, wezterm, iTerm2, etc. Piped or redirected, it quietly falls back to a normal tqdm. Terminal size is read once at startup.

Metadata

Release files for tqdm-overflow 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tqdm-overflow 0.1.0
File Size Uploaded
tqdm_overflow-0.1.0.tar.gz 10.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for tqdm-overflow 0.1.0
File Interpreter ABI Platform
tqdm_overflow-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.6 kB

Release files / tqdm_overflow-0.1.0.tar.gz

Download URL tqdm_overflow-0.1.0.tar.gz
Size 10.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9309e8b1a5ff7ea2e55b21f7cfe048ea8bbd9ef668f5fbb08939d6cebe8fb41e
BLAKE2b-256 checksum
How to use checksums
cec6c7b5f5d83ecce041e7cf1666a627ba66280965a15614481195e7d0fb3937
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / tqdm_overflow-0.1.0-py3-none-any.whl

Download URL tqdm_overflow-0.1.0-py3-none-any.whl
Size 9.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d8c11f93f8a62e1fc54e4204ce56858b0e8c900f637a83e58181bd3322c8d021
BLAKE2b-256 checksum
How to use checksums
095fee33ed98795ad6919c39e2e6b1227717ee0eab527ce05fef73be33ad7252
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page