{"id":16190675,"url":"https://github.com/tiagocoutinho/progresso","last_synced_at":"2025-07-25T23:33:26.652Z","repository":{"id":228338131,"uuid":"773704846","full_name":"tiagocoutinho/progresso","owner":"tiagocoutinho","description":"Python progress iterators/generators made easy","archived":false,"fork":false,"pushed_at":"2024-04-03T11:45:31.000Z","size":30,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-15T15:47:00.775Z","etag":null,"topics":["generator-python","iterators","progress","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tiagocoutinho.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-03-18T08:50:58.000Z","updated_at":"2024-03-18T09:48:51.000Z","dependencies_parsed_at":"2024-03-22T21:27:56.410Z","dependency_job_id":"d94b444c-e7cf-4511-a4b1-70544d3a55df","html_url":"https://github.com/tiagocoutinho/progresso","commit_stats":null,"previous_names":["tiagocoutinho/progresso"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagocoutinho%2Fprogresso","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagocoutinho%2Fprogresso/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagocoutinho%2Fprogresso/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagocoutinho%2Fprogresso/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tiagocoutinho","download_url":"https://codeload.github.com/tiagocoutinho/progresso/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247668939,"owners_count":20976292,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["generator-python","iterators","progress","python"],"created_at":"2024-10-10T07:43:53.316Z","updated_at":"2025-04-07T14:28:37.177Z","avatar_url":"https://github.com/tiagocoutinho.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# progresso\n\n[![progresso][pypi-version]](https://pypi.python.org/pypi/progresso)\n[![Python Versions][pypi-python-versions]](https://pypi.python.org/pypi/progresso)\n![License][license]\n[![CI][CI]](https://github.com/tiagocoutinho/progresso/actions/workflows/ci.yml)\n\n\nA simple library that aims at making hierarchical progress\niterators / generators easy.\n\nA single point API: `progresso(it: Iterable, start: float = 0, end: float = 100) -\u003e Iterable`\n\nI'll use the term task to mean any python iterable or generator.\n\nRules of the game:\n\n1. Each task is responsible of generating (yielding) incremental progress between [0, 100].\n2. The task is free to generate any number of steps (min 1)\n3. The task is free to start at any point as long as the value is between [0,100]\n4. Value is truncated to max(value, 0)\n5. Value is truncated to min(value, 100)\n6. If a value is less than previous it is discarded (I can be convinced otherwise to emulate\n   progress regressing)\n7. If the task last value is less than 100, an extra value 100 is generated\n\nExample:\n\n```python\n\u003e\u003e\u003e def task_1():\n...     yield 10\n...     yield 90\n...     yield 100\n...\n\n\u003e\u003e\u003e def task_2():\n...     yield 5\n...     yield 2\n...     yield 99\n...\n\n\u003e\u003e\u003e def task():\n...     yield 30\n...     yield from progresso(task_1(), 30, 60)\n...     yield from progresso(task_2(), 60, 90)\n\n\u003e\u003e\u003e for i in progresso(task()):\n...     print(i)\n30.0\n33.0\n57.0\n60.0\n61.5\n89.7\n90.0\n100.0\n```\n\n[pypi-python-versions]: https://img.shields.io/pypi/pyversions/progresso.svg\n[pypi-version]: https://img.shields.io/pypi/v/progresso.svg\n[pypi-status]: https://img.shields.io/pypi/status/progresso.svg\n[license]: https://img.shields.io/pypi/l/progresso.svg\n[CI]: https://github.com/tiagocoutinho/progresso/actions/workflows/ci.yml/badge.svg\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagocoutinho%2Fprogresso","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftiagocoutinho%2Fprogresso","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagocoutinho%2Fprogresso/lists"}