--- id: flake8-async version: "26.7.1" license: MIT license_treatment: permissive maintenance: active --- # flake8-async — A highly opinionated flake8 plugin for Trio-related problems. License: permissive · Maintenance: active · Downloads: 351.9K/mo ## What it is and what it does flake8-async is a flake8 plugin that integrates async-specific linting rules for Trio, AnyIO, and asyncio code. It detects a range of issues from outright bugs to idiom violations that may signal misunderstandings of async patterns. The plugin reports problems using ASYNC-prefixed error codes and is designed to catch issues that general linters might miss in async contexts. The plugin depends on libcst for code parsing and integrates directly into flake8's workflow. It is actively maintained and supports Python 3.9 through 3.13. The description notes it can be opinionated and potentially noisy depending on your coding style, and suggests pairing it with flake8-bugbear for broader coverage. Use it for: - Catch common async bugs and antipatterns in Trio-based applications before they reach production. - Enforce consistent async idioms across a team's asyncio or AnyIO codebases during code review. - Identify dead or pointless async code that may indicate misunderstanding of concurrency patterns. - Detect likely performance issues in async functions that could cause bottlenecks or blocking. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A flake8 plugin that detects async-related issues in code using Trio, AnyIO, or asyncio, flagging bugs, dead code, performance problems, and idiom violations. Yes, if you write async code with Trio, AnyIO, or asyncio and want linting coverage beyond general flake8 checks. The low install friction, active maintenance, MIT license, and zero known vulnerabilities make it a safe addition. Be aware it is opinionated and may flag code you consider acceptable; review its rule documentation to decide if its strictness matches your team's standards. ## Install pip install flake8-async uv add flake8-async poetry add flake8-async ## Installing flake8-async Before you install: Low friction installation with a single runtime dependency (libcst). The project is actively maintained with a recent release and no known vulnerabilities. License in practice: MIT license is permissive; you can use this plugin freely in commercial and private projects with minimal restrictions. Quickstart: pip install flake8-async # Then run flake8 on your async code: flake8 your_async_file.py # The plugin integrates automatically with flake8 and reports ASYNC-prefixed errors. Requires Python 3.9 or later and an existing flake8 installation. Verify before relying: - Whether the plugin's checks overlap significantly with ruff's async checks or if they complement each other. - How noisy the checks are in typical async codebases and whether filtering is commonly needed. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 351.9K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags flake8 async linter, trio asyncio code checker, async code quality plugin, flake8 async bugs, anyio trio linter, async-linting, trio-anyio-asyncio [View on SkillFed](https://skillfed.io/packages/flake8-async) · [View on PyPI](https://pypi.org/project/flake8-async/)