{"id":16516865,"url":"https://github.com/alkasm/streamtools","last_synced_at":"2026-06-04T22:31:18.733Z","repository":{"id":123352321,"uuid":"145471632","full_name":"alkasm/streamtools","owner":"alkasm","description":"Tools for working with Redis Streams","archived":false,"fork":false,"pushed_at":"2018-08-20T21:22:41.000Z","size":3,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-13T05:29:06.193Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/alkasm.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-08-20T21:18:55.000Z","updated_at":"2018-10-29T22:59:41.000Z","dependencies_parsed_at":"2023-11-23T16:30:18.648Z","dependency_job_id":null,"html_url":"https://github.com/alkasm/streamtools","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/alkasm%2Fstreamtools","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alkasm%2Fstreamtools/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alkasm%2Fstreamtools/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alkasm%2Fstreamtools/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alkasm","download_url":"https://codeload.github.com/alkasm/streamtools/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241549122,"owners_count":19980477,"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-10-11T16:27:21.706Z","updated_at":"2026-06-04T22:31:18.721Z","avatar_url":"https://github.com/alkasm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Example Usage\n\n```python\nfrom streamtools import StreamsClient, StreamsInteractor, StreamsReader\nimport random\n\n# start the Redis Streams client\nclient = StreamsClient('localhost')\n\n# write some random stuff to two streams\nwriter = StreamsInteractor(client)\nfor i in range(100):\n    x = random.randint(0, 100)\n    writer.xadd('ex-stream-1', **{'x': x, 'x+5': x + 5})\n    writer.xadd('ex-stream-2', **{'x': x, 'x+7': x + 7})\n\n# iterate through all values written, starting with the earliest values\nstreams = {'ex-stream-1': 0, 'ex-stream-2': 0}\nreader = StreamsReader(client, streams, continuous=False)\nfor data in reader:\n    print(data)\n```\n\n\u003e StreamData(id='1534799601773-0', key='ex-stream-1', data={'x+5': '26', 'x': '21'})  \n\u003e StreamData(id='1534799601773-0', key='ex-stream-2', data={'x+7': '28', 'x': '21'})  \n\u003e StreamData(id='1534799601773-1', key='ex-stream-1', data={'x+5': '34', 'x': '29'})  \n\u003e StreamData(id='1534799601773-1', key='ex-stream-2', data={'x+7': '36', 'x': '29'})  \n\u003e StreamData(id='1534799601774-0', key='ex-stream-1', data={'x+5': '41', 'x': '36'})  \n\u003e StreamData(id='1534799601774-0', key='ex-stream-2', data={'x+7': '43', 'x': '36'})  \n\u003e ...  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falkasm%2Fstreamtools","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falkasm%2Fstreamtools","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falkasm%2Fstreamtools/lists"}