astral-sh / astral-sh/ruff

Support for `flake8-annotations-coverage`

Open
#3,210 6 comments 0 reactions 0 assignees View on GitHub
needs-decision plugin
Dominant language
Rust
Stars
49.7k
Forks
2.4k
Avg merge
2d 1h
Merged PRs (30d)
458

Description

Hey, we are currently using [`flake8-annotations-coverage`](https://github.com/best-doctor/flake8-annotations-coverage) in our FOSS [`py-template`](https://github.com/inovintell/py-template) project, but we would like to move to `ruff` exclusively from `flake8` + `flakeheaven`.

This plugin basically allows you to set minimum percentage coverage for annotations and raise if it is not fulfilled.

### Error Codes

- TAE001 - Too few type annotations in file

Is support for [`flake8-annotations-coverage`](https://github.com/best-doctor/flake8-annotations-coverage) planned/would be considered? Unfortunately we cannot pick up this issue ourselves at the current time.

Contributor guide

Open the contributing guide

Research direction

Start by reading the linked flake8-annotations-coverage project and its definition of TAE001, then compare that behavior with Ruff's existing annotation-related linting. Determine the supported configuration and expected diagnostics before identifying the appropriate Ruff entry point. Done means Ruff can enforce a minimum annotation percentage and report TAE001-equivalent failures with coverage tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, rust
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.