# agronholm/anyio

High level asynchronous concurrency and networking framework that works on top of either Trio or asyncio

Repository: https://github.com/agronholm/anyio
Canonical: https://ross.abutalabs.com/products/anyio
Language: Python
License: MIT
License Family: permissive
Topics: async-await, trio, asyncio
Last push: 2026-08-25T16:28:26+00:00

## Health v2 (maintenance only)
Score: 93/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 80, longevity 100
- inputs: {"age_days": 2936, "days_push": 8, "days_rel": 52, "gap_med": 33.0, "n_releases_24m": 17}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2537, forks 247 (observed 2026-08-28T04:06:59.152116+00:00)

## What it is
AnyIO is a high-level asynchronous concurrency and networking library for Python that runs on top of either asyncio or Trio. It provides Trio-style structured concurrency, task groups, async networking primitives, and a pytest plugin, letting code run unmodified on either async backend.

## Use cases
- write async python code that works on both asyncio and trio
- structured concurrency with task groups in asyncio
- async tcp and udp socket networking
- run async tests with pytest and async fixtures
- async file io and subprocess handling
- migrate a library from asyncio to trio incrementally

## When to choose
- you need backend-agnostic async code portable across asyncio and trio
- you want trio-like structured concurrency on asyncio
- you need high-level async networking, streams, and synchronization primitives
- you want async pytest testing with hypothesis support

## When to avoid
- you only target one backend and are happy with its native APIs
- you need a full web framework rather than a concurrency library
- you work outside the Python ecosystem

## Facets
- artifact type: library
- maturity: stable
- function: concurrency, networking, testing, http-server
- domain: developer-tools, backend, networking, apis
- platform: python, cross-platform
- tags: asyncio, trio, structured-concurrency, async-await, task-groups, pytest-plugin

## Member repositories
- agronholm/anyio (main) score 93

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:59.152116+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:25:12.497363+00:00, confidence not recorded.
  - readme: https://github.com/agronholm/anyio (fetched 2026-08-28T04:06:59.152116+00:00, sha 050db7ea42de)
  - registry_pypi: https://pypi.org/pypi/anyio/json (fetched 2026-08-29T10:07:15.094322+00:00, sha 7d014b3b4b2a)
- Data as of 2026-08-30T08:39:29.467469+00:00.
