{"id":21999143,"url":"https://github.com/frizensami/streamlimit-utils","last_synced_at":"2025-03-23T05:20:47.969Z","repository":{"id":54808539,"uuid":"300554373","full_name":"frizensami/streamlimit-utils","owner":"frizensami","description":"Stream limiting functions","archived":false,"fork":false,"pushed_at":"2021-01-28T04:07:23.000Z","size":29,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-01-28T11:48:24.055Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/frizensami.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-10-02T08:44:40.000Z","updated_at":"2020-10-15T16:36:11.000Z","dependencies_parsed_at":"2022-08-14T03:30:57.729Z","dependency_job_id":null,"html_url":"https://github.com/frizensami/streamlimit-utils","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frizensami%2Fstreamlimit-utils","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frizensami%2Fstreamlimit-utils/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frizensami%2Fstreamlimit-utils/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frizensami%2Fstreamlimit-utils/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/frizensami","download_url":"https://codeload.github.com/frizensami/streamlimit-utils/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245058058,"owners_count":20554053,"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":[],"created_at":"2024-11-29T22:27:50.124Z","updated_at":"2025-03-23T05:20:47.945Z","avatar_url":"https://github.com/frizensami.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Stream Limiting Utils\n\nQuick-and-dirty utils for limiting a row-generating function to simulate a stream of data.\n\nTwo types of stream limiting:\n\n- Off-the-shelf limiting library\n``` python\ndef construct_ratelimit_rows(row_generator_fx, max_rows_per_minute, blocking=True):\n```\n\n- Generic rate limiter that calls functions to find amount of rows to return and sleep time\n\n``` python\ndef construct_generic_limited_rows(row_generator_fx, rows_function, sleep_function):\n```\n\nFor the latter, there are util functions to make life easier. E.g., for a random interval:\n\n``` python\ndef construct_randomsleep_rows(row_generator_fx, min_sleep, max_sleep, rows=1):\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrizensami%2Fstreamlimit-utils","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrizensami%2Fstreamlimit-utils","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrizensami%2Fstreamlimit-utils/lists"}