flake8-unused-arguments

raw JSON →
0.0.14 verified Fri May 01 auth: no python

A flake8 extension that warns on unused function arguments. Current version 0.0.14. Infrequently maintained; last release 2020.

pip install flake8-unused-arguments
error flake8: `flake8-unused-arguments` is not installed or not found. Use `pip install flake8-unused-arguments` and ensure it's in the same environment as flake8.
cause Package not installed or flake8 not finding the plugin.
fix
Run pip install flake8-unused-arguments in the same Python environment as flake8.
error U100 no longer shown in flake8 output
cause Plugin incompatible with newer flake8 versions (>=4.0).
fix
Downgrade flake8 to 3.x with pip install 'flake8<4'.
gotcha Plugin may not work with flake8 >= 4.0 due to internal API changes.
fix Use a different linting tool or pin flake8 to version 3.x.
gotcha The plugin ignores arguments that start with an underscore (e.g., `_arg`).
fix Prefix intentionally unused arguments with underscore to suppress warnings.
deprecated No updates since 2020; consider migrating to ruff (U100 rule) which is actively maintained.
fix Run `pip install ruff` and use `ruff check --select U100`.

Install the package and flake8 will automatically detect the plugin. Use --select=U100 to show only unused argument warnings.

# Just install; then run flake8 on your code
# Example file: test.py
def foo(x, y):
    return x
# Run: flake8 --select=U100 test.py
# Output: test.py:1:11: U100 Unused argument 'y'