From 76e7fefc1d98cb5602cb1c33d7196f75b674a6a3 Mon Sep 17 00:00:00 2001 From: "Michael A. Smith" Date: Wed, 19 Jul 2023 22:49:07 -0400 Subject: [PATCH] AVRO-3807: Implement Autoflake in Lint --- lang/py/pyproject.toml | 8 ++++++++ lang/py/tox.ini | 2 ++ 2 files changed, 10 insertions(+) diff --git a/lang/py/pyproject.toml b/lang/py/pyproject.toml index 675e976379a..87282befaf0 100644 --- a/lang/py/pyproject.toml +++ b/lang/py/pyproject.toml @@ -25,3 +25,11 @@ line-length = 150 [tool.isort] profile = 'black' + +[tool.autoflake] +check-diff = true +expand-star-imports = true +remove-all-unused-imports = true +remove-duplicate-keys = true +remove-unused-variables = true +recursive = true diff --git a/lang/py/tox.ini b/lang/py/tox.ini index ababc1411cb..00b1f984c1e 100644 --- a/lang/py/tox.ini +++ b/lang/py/tox.ini @@ -69,10 +69,12 @@ commands_post = [testenv:lint] deps = + autoflake black isort commands_pre = commands = + autoflake . black --check . isort --check-only . commands_post =