{"id":19598475,"url":"https://github.com/sphericalkat/eidolon","last_synced_at":"2025-04-27T16:31:49.949Z","repository":{"id":173158864,"uuid":"650322249","full_name":"SphericalKat/eidolon","owner":"SphericalKat","description":"A utility to concurrently make HTTP requests, with an optional rate limit. Powered by asyncio and aiohttp.","archived":false,"fork":false,"pushed_at":"2025-01-31T19:49:58.000Z","size":51,"stargazers_count":3,"open_issues_count":3,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-05T01:22:36.250Z","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SphericalKat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-06-06T20:30:10.000Z","updated_at":"2023-11-12T12:37:31.000Z","dependencies_parsed_at":null,"dependency_job_id":"0fbe54c9-1cb6-4f26-88d3-162a8397aff8","html_url":"https://github.com/SphericalKat/eidolon","commit_stats":null,"previous_names":["sphericalkat/eidolon"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SphericalKat%2Feidolon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SphericalKat%2Feidolon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SphericalKat%2Feidolon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SphericalKat%2Feidolon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SphericalKat","download_url":"https://codeload.github.com/SphericalKat/eidolon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251171293,"owners_count":21547087,"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-11T09:06:27.187Z","updated_at":"2025-04-27T16:31:49.705Z","avatar_url":"https://github.com/SphericalKat.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Eidolon\nA utility to concurrently make HTTP requests, with an optional rate limit. Powered by asyncio and aiohttp.\n\n## Installation\nInstall and update via [pip](https://pip.pypa.io/en/stable/getting-started/)\n```bash\npip install --U eidolon\n```\n\n## A Simple Example\n```py3\nimport asyncio\nimport logging\nfrom eidolon import Parallelizer\nfrom eidolon.api_request import APIRequest\n\n\"\"\"\nthe callback should ideally be an async function, since methods\nlike .json or .text on the response are async\n\"\"\"\n\nasync def callback(request, response):\n    print(response.status)\n    print(await response.text())\n\n\"\"\"\nCreate an APIRequest object. Each object corresponds to a single request, and can take in an optional callback\nEverything except request_method and request_url is optional\n\"\"\"\nreq = APIRequest(\n    request_method=\"GET\",\n    request_url=\"https://www.google.com\",\n    request_headers={\"User-Agent\": \"Mozilla/5.0\"},\n    request_params={\"q\": \"python\"},\n    request_json={\"key\": \"value\"},\n    request_form_data={\"key\": \"value\"},\n    callback=callback,\n)\n\np = Parallelizer(\n    logging_level=logging.INFO, # default: logging.ERROR\n    max_requests_per_second=10, # default: 1\n    max_retry_attempts=1, # default: 3\n    seconds_to_sleep_after_rate_limit_error=10, # default: 15\n)\n\n# make 100 requests\nasyncio.run(p.make_requests([req] * 100))\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsphericalkat%2Feidolon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsphericalkat%2Feidolon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsphericalkat%2Feidolon/lists"}