From f7a95f293e9f60b3262cf0cfd2386966d137894b Mon Sep 17 00:00:00 2001 From: Romuald Brunet Date: Wed, 1 Aug 2018 15:34:11 +0200 Subject: [PATCH] bpo-34307: Allow any argument in NullHandler The Nullhandler might be used as a drop-in replacement to a custom logger, in that case the initialization would fail when the logging configuration contains additional arguments --- Lib/logging/__init__.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Lib/logging/__init__.py b/Lib/logging/__init__.py index 29a7d464decf98..032340b7814385 100644 --- a/Lib/logging/__init__.py +++ b/Lib/logging/__init__.py @@ -2037,6 +2037,9 @@ class NullHandler(Handler): a NullHandler and add it to the top-level logger of the library module or package. """ + def __init__(self, *args, **kwargs): + """Stub.""" + def handle(self, record): """Stub."""