{"id":32175503,"url":"https://github.com/parsiad/lazy-table","last_synced_at":"2025-10-21T19:40:25.918Z","repository":{"id":44643730,"uuid":"410201193","full_name":"parsiad/lazy-table","owner":"parsiad","description":"A python-tabulate wrapper for producing tables from generators","archived":false,"fork":false,"pushed_at":"2022-11-05T19:08:45.000Z","size":190,"stargazers_count":57,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-21T12:42:50.739Z","etag":null,"topics":["lazy-evaluation","python","tables"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/lazy-table","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/parsiad.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}},"created_at":"2021-09-25T07:01:30.000Z","updated_at":"2025-05-29T12:15:12.000Z","dependencies_parsed_at":"2022-09-13T15:12:28.658Z","dependency_job_id":null,"html_url":"https://github.com/parsiad/lazy-table","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/parsiad/lazy-table","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiad%2Flazy-table","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiad%2Flazy-table/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiad%2Flazy-table/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiad%2Flazy-table/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/parsiad","download_url":"https://codeload.github.com/parsiad/lazy-table/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiad%2Flazy-table/sbom","scorecard":{"id":720973,"data":{"date":"2025-08-11","repo":{"name":"github.com/parsiad/lazy-table","commit":"160cff60fb28ab5eb03068e726cc4d4467a563cd"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.8,"checks":[{"name":"Code-Review","score":0,"reason":"Found 1/19 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/tox.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tox.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/parsiad/lazy-table/tox.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tox.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/parsiad/lazy-table/tox.yml/main?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/tox.yml:22","Warn: pipCommand not pinned by hash: .github/workflows/tox.yml:23","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 7 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-22T11:21:11.761Z","repository_id":44643730,"created_at":"2025-08-22T11:21:11.761Z","updated_at":"2025-08-22T11:21:11.761Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280325180,"owners_count":26311414,"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","status":"online","status_checked_at":"2025-10-21T02:00:06.614Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["lazy-evaluation","python","tables"],"created_at":"2025-10-21T19:40:24.331Z","updated_at":"2025-10-21T19:40:25.908Z","avatar_url":"https://github.com/parsiad.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![](https://github.com/parsiad/lazy-table/actions/workflows/tox.yml/badge.svg)\n[![](https://static.pepy.tech/personalized-badge/lazy-table?period=total\u0026units=international_system\u0026left_color=grey\u0026right_color=blue\u0026left_text=pypi%20downloads)](https://pepy.tech/project/lazy-table)\n[![](https://badge.fury.io/py/lazy-table.svg)](https://badge.fury.io/py/lazy-table)\n![](https://img.shields.io/pypi/pyversions/lazy-table.svg)\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"lazy_table\" src=\"https://raw.githubusercontent.com/parsiad/lazy-table/master/logo.png\"\u003e\n\u003c/p\u003e\n\nA [python-tabulate](https://github.com/astanin/python-tabulate) wrapper for producing tables from generators.\n\n## Motivation\n\nlazy_table is useful when (*i*) each row of your table is generated by a possibly expensive computation and (*ii*) you want to print rows to the screen as soon as they are available.\n\nFor example, the rows in the table below correspond to [numerically solving an ordinary differential equation](https://en.wikipedia.org/wiki/Numerical_methods_for_ordinary_differential_equations) with progressively more steps. See [examples/euler_vdp.py](https://raw.githubusercontent.com/parsiad/lazy-table/master/examples/euler_vdp.py) for the code to generate this table.\n\n![](https://github.com/parsiad/lazy-table/blob/main/examples/euler_vdp.gif?raw=true)\n\nHere is the same example with a progress bar.\n\n![](https://github.com/parsiad/lazy-table/blob/main/examples/euler_vdp_with_progress.gif?raw=true)\n\n## Installation and usage\n\nInstall lazy_table via pip:\n\n```console\n$ pip install lazy_table\n```\n\nIn your Python code, add\n\n```python\nimport lazy_table as lt\n```\n\nNow, generating your own lazy table is as simple as calling `lt.stream` on a generator that yields one or more lists, where each list is a row of your table (see the example below).\n\n## Example\n\nAs a toy example, consider printing the first 10 [Fibonacci numbers](https://en.wikipedia.org/wiki/Fibonacci_number) in a table.\nSince this is a relatively cheap operation, we will pretend it is expensive by adding an artificial `sleep(1)` call beteween Fibonacci numbers.\n\n```python\nimport time\nimport lazy_table as lt\n\ndef fib_table(n):\n     x0, x1 = 0, 1\n     yield [0, x0]\n     yield [1, x1]\n     for i in range(2, n + 1):\n         time.sleep(1)  # Simulate work\n         x0, x1 = x1, x0 + x1\n         yield [i, x1]\n\nlt.stream(fib_table(10), headers=['N', 'F_N'])\n```\n\nYour final table should look like this:\n\n```\n  N    F_N\n---  -----\n  0      0\n  1      1\n  2      1\n  3      2\n  4      3\n  5      5\n  6      8\n  7     13\n  8     21\n  9     34\n 10     55\n```\n\nYou can also specify an \"artist\" that determines how the table is rendered.\nFor example, the `ConsoleWithProgress` artist displays a progress bar alongside the table indicating the percentage of rows completed:\n\n```python\nn = 10\nartist = lt.artists.ConsoleWithProgress()\nlt.stream(fib_table(n), headers=['N', 'F_N'], n_rows=n + 1, artist=artist)\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparsiad%2Flazy-table","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparsiad%2Flazy-table","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparsiad%2Flazy-table/lists"}