HomePhabricator

Check for unused imports in *.py files

Description

Check for unused imports in *.py files

Summary:
Using flake8 code F401, unused imports are output as lint errors from
acanist.
flake8 is preferred here over pylint because it offers more feature for
the long-term improvement. It could also throw pep8 errors but will not
fix them like autopep8 does, so better use both.

Based on core PR11835

Depends on D2445, D2446, D2447, D2448, D2449, D2450

Test Plan:
Add an unused import in a py file and run arc lint. An error should be
reported
Read the CONTRIBUTING.md doc

Reviewers: #bitcoin_abc, deadalnix, jasonbcox

Reviewed By: #bitcoin_abc, jasonbcox

Subscribers: teamcity, schancel

Differential Revision: https://reviews.bitcoinabc.org/D2451

Details

Provenance
FabienAuthored on Jan 30 2019, 13:36
FabienPushed on Jan 31 2019, 11:07
Reviewer
Restricted Project
Differential Revision
D2451: Check for unused imports in *.py files
Parents
rABCaadde70bfcb4: Use compile-time constants instead of unnamed enumerations
Branches
Unknown
Tags
Unknown