$npx skillfedfor your agent

flake8-return

Flake8 plugin that checks return values

With conditionsPyPI Quality AssuranceReleased Oct 2022603.1K downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — flake8_return-1.2.0-py3-none-any.whl
v1.2.0 · released 2022-10-28 · Python >=3.6,<4.0 · 1 runtime deps: flake8-plugin-utils

Yes, if you use flake8 and want to enforce return statement consistency. The plugin is low-friction to install, has no known vulnerabilities, and covers a useful gap in standard flake8 checks. The aging maintenance status is a minor concern—last release was 2022-10-28—but the repository remains active and the plugin's scope is narrow enough that it is unlikely to break with minor Python or flake8 updates. Install it if your team values clean return patterns; skip it if you already enforce these rules through code review or a different linter.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires flake8 to be installed and configured; the plugin integrates into flake8's linting pipeline and does not work standalone.
  • Low friction installation with a single lightweight runtime dependency.
  • The package is aging—last release was 2022-10-28—but the repository remains active with recent commits and no archived status, suggesting maintenance continues despite infrequent version bumps.

License · maintenance · safety

MIT (permissive) — MIT license (permissive) places no restrictions on use, modification, or distribution in proprietary or open-source projects.

last release 2022-10-28 (1386 days) · last repo commit 2025-10-08 · 60 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 603,124 downloads/mo, #5,812 on PyPI

Verify before relying

pip install flake8-return

# Then run flake8 on your code; the plugin activates automatically
flake8 your_file.py

# Example: this will trigger R501
def example(x):
    if not x:
        return
    return None
  • Whether the aging maintenance status (last release 2022-10-28, 1386 days ago) affects compatibility with recent Python or flake8 versions.
  • Performance impact on large codebases or whether there are known false positives beyond those documented in the changelog.
Same gist for agents: .md · .json

What it is and what it does

flake8-return is a flake8 plugin that enforces consistent and clean return statement patterns in Python code. It detects eight categories of return-related issues: explicit None returns when unnecessary, implicit None returns in functions that can return non-None values, missing explicit returns at function end, unnecessary variable assignments before returns, and redundant else blocks after return, raise, continue, or break statements. The plugin also supports asyncio coroutines.

You install it alongside flake8, and it runs automatically during linting without requiring separate configuration. It flags violations with error codes R501 through R508, each targeting a specific anti-pattern. The plugin depends on flake8-plugin-utils for its implementation and works with Python versions from 3.6 onward.

Use it for

  • Enforce consistent return behavior across a codebase to catch functions that sometimes return None implicitly and sometimes explicitly.
  • Simplify control flow by detecting and removing unnecessary else blocks after return or raise statements.
  • Catch unnecessary intermediate variable assignments that serve no purpose before a return.
  • Ensure all code paths in a function that can return a value have an explicit return statement.
  • Maintain code style consistency in teams by automatically flagging return-related anti-patterns during CI/CD linting.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you use flake8 and want to enforce return statement consistency.

The plugin is low-friction to install, has no known vulnerabilities, and covers a useful gap in standard flake8 checks. The aging maintenance status is a minor concern—last release was 2022-10-28—but the repository remains active and the plugin's scope is narrow enough that it is unlikely to break with minor Python or flake8 updates. Install it if your team values clean return patterns; skip it if you already enforce these rules through code review or a different linter.

Install

flake8-return on PyPI

Before you install

Low friction installation with a single lightweight runtime dependency. The package is aging—last release was 2022-10-28—but the repository remains active with recent commits and no archived status, suggesting maintenance continues despite infrequent version bumps.

Requires flake8 to be installed and configured; the plugin integrates into flake8's linting pipeline and does not work standalone.

License in practice

MIT license (permissive) places no restrictions on use, modification, or distribution in proprietary or open-source projects.

Quickstart

pip install flake8-return

# Then run flake8 on your code; the plugin activates automatically
flake8 your_file.py

# Example: this will trigger R501
def example(x):
    if not x:
        return
    return None

Verify before relying

  • Whether the aging maintenance status (last release 2022-10-28, 1386 days ago) affects compatibility with recent Python or flake8 versions.
  • Performance impact on large codebases or whether there are known false positives beyond those documented in the changelog.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.6,<4.0
Install frictionLow. Pure-Python wheel
Runtime dependencies
1 package
flake8-plugin-utils
MaintenanceAging 1,386 days since the last release
Last repo commit
First released
Downloads603,124 / month, #5,812 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
License :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

Evidence: flake8_return-1.2.0-py3-none-any.whl

Tags

Capabilities
flake8 return value lintingcheck return statementsdetect unnecessary else blockspython return pattern checkerflake8 plugin qualityfunction return analysiscode style return validation
Topics
flake8-plugincode-qualitylinting
PyPI keywords
flake8pluginreturn

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “flake8 return value linting”

  • flake8-returnA flake8 plugin that detects and flags problematic return statement…
  • flake8-annotationsA Flake8 plugin that enforces PEP 3107-style function type…
  • flake8-functionsA flake8 extension that enforces function-level code quality rules:…

Give your agent the search over MCP, or paste the wish link into any chat.

More Quality Assurance packages

coverage Worth it
PyPI · Testing · released Aug 2026

Coverage.py measures which lines of Python code are executed during test runs, reporting coverage percentages and identifying untested code paths.

Install it if you want to measure test completeness or enforce coverage thresholds in your project.

permissive licensepure Python · 3.10+
335.8Mdownloads / mo
ruff Worth it
PyPI · Python Modules · released Aug 2026

Ruff is a Python linter and code formatter written in Rust that combines linting, formatting, and code fixing into a single tool, replacing Flake8, Black, isort, and related utilities.

MITcompiled wheel · 3.7+
316.1Mdownloads / mo
pexpect With conditions
PyPI · Software Development · released Nov 2023

Pexpect spawns and controls interactive console applications by sending input and matching output patterns, automating tasks that would otherwise require manual interaction.

ISCpure Pythonaging
200.8Mdownloads / mo
black Worth it
PyPI · Python Modules · released May 2026

Black reformats Python source code to a consistent style by parsing entire files and rewriting them according to an opinionated, deterministic set of rules, eliminating manual formatting decisions.

MITpure Python · 3.10+
179.9Mdownloads / mo
pytest-xdist Worth it
PyPI · Utilities · released Jul 2025

pytest-xdist distributes pytest tests across multiple CPU cores or machines to speed up test execution, with the simplest usage being `pytest -n auto` to spawn workers equal to available CPUs.

Install it if your test suite takes long enough that parallelization would save meaningful time.

MITpure Python · 3.9+
177.1Mdownloads / mo
cfn-lint Worth it
PyPI · Quality Assurance · released Aug 2026

Validates AWS CloudFormation templates in YAML or JSON format against resource provider schemas and best practices, checking property values and configuration correctness.

Install it if you work with CloudFormation templates.

MIT-0pure Python
114.9Mdownloads / mo

See also flake8-pie · flake8-plugin-utils · flake8-pytest-style · flake8-unused-arguments · flake8-comprehensions · flake8-print · flake8-noqa · flake8-implicit-str-concat · flake8_simplify · flake8-tidy-imports