From aef9ad9dacdac458ed8b5c55ce919a429b1bad71 Mon Sep 17 00:00:00 2001 From: Akihiro Motoki Date: Fri, 21 Feb 2020 05:49:20 +0900 Subject: [PATCH] Disable old-style-class check by default In Python3, all objects inherit 'object' and there is no need to inherit 'object' in class declarations as we do in python2. pylint 2.0 added a new check useless-object-inheritance and if this check is enabled in pylint, we need to disable the old-style-class check in hacking. We are now in py3 era, so it sounds good to disable it by default. Change-Id: Iaebcf267de9ef826b8cc387d1fa1f2eccff2c050 --- hacking/checks/python23.py | 1 + 1 file changed, 1 insertion(+) diff --git a/hacking/checks/python23.py b/hacking/checks/python23.py index 91bc6396..80b911b9 100644 --- a/hacking/checks/python23.py +++ b/hacking/checks/python23.py @@ -209,6 +209,7 @@ RE_NEW_STYLE_CLASS = re.compile(r"^class [^(]+\(.+\):") @core.flake8ext +@core.off_by_default def hacking_no_old_style_class(logical_line, noqa): r"""Check for old style classes.