From bd96b470d0a74337927dbcbc789bdf206b57b905 Mon Sep 17 00:00:00 2001 From: Samuel Searles-Bryant Date: Tue, 23 Aug 2022 09:22:11 +0100 Subject: [PATCH] Add missing error code to message for B024 Resolves #275 --- bugbear.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bugbear.py b/bugbear.py index 77fad29..ae714ce 100644 --- a/bugbear.py +++ b/bugbear.py @@ -1173,8 +1173,9 @@ def visit_Lambda(self, node): B023 = Error(message="B023 Function definition does not bind loop variable {!r}.") B024 = Error( message=( - "{} is an abstract base class, but it has no abstract methods. Remember to use" - " @abstractmethod, @abstractclassmethod and/or @abstractproperty decorators." + "B024 {} is an abstract base class, but it has no abstract methods. Remember to" + " use @abstractmethod, @abstractclassmethod and/or @abstractproperty" + " decorators." ) )