{"id":17836280,"url":"https://github.com/buhman/mhtg","last_synced_at":"2025-04-02T13:20:17.628Z","repository":{"id":145208198,"uuid":"178790553","full_name":"buhman/mhtg","owner":"buhman","description":"minimal h11/trio glue","archived":false,"fork":false,"pushed_at":"2019-04-01T06:18:26.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-08T04:25:52.257Z","etag":null,"topics":["async","http","python","trio"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/buhman.png","metadata":{"files":{"readme":"README.rst","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":"2019-04-01T05:18:17.000Z","updated_at":"2019-04-01T05:51:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"4c9797b8-ac77-4fb1-87bc-d6911f477013","html_url":"https://github.com/buhman/mhtg","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buhman%2Fmhtg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buhman%2Fmhtg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buhman%2Fmhtg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buhman%2Fmhtg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/buhman","download_url":"https://codeload.github.com/buhman/mhtg/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246819780,"owners_count":20839095,"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":["async","http","python","trio"],"created_at":"2024-10-27T20:37:22.829Z","updated_at":"2025-04-02T13:20:17.608Z","avatar_url":"https://github.com/buhman.png","language":"Python","readme":"mhtg: minimal h11/trio glue\n===========================\n\nfeatures\n--------\n\n- h11_, a transport agnostic standards-compliant http/1.1 implementation\n- trio_, an async/await-native IO library focused on usability and correctness\n\n.. _trio: https://github.com/python-trio/trio\n.. _h11: https://github.com/python-hyper/h11\n\nusage\n-----\n\ncontrived example:\n\n.. code-block:: python\n\n   from functools import partial\n   from mhtg import client, context, model\n   import trio\n\n   client_factory = partial(client.client_factory,\n                            server_hostname=\"google.com\",\n                            port=443)\n\n   connection_manager = context.make_connection_manager(client_factory)\n\n   def request_builder():\n       request = h11.Request(method=\"GET\",\n                             target=\"/\",\n                             headers=[\n                                 (\"host\", server_hostname),\n                                 (\"content-length\", 0),\n                             ])\n\n       return request,\n\n   async def do():\n       async with connection_manager() as reuse_connection:\n           async with reuse_connection() as make_request:\n               await make_request(*request_builder())\n\n   trio.run(do)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuhman%2Fmhtg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbuhman%2Fmhtg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuhman%2Fmhtg/lists"}