]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-46063: Add 'delay=True' to file handler initialization. (GH-30103)
authorVinay Sajip <vinay_sajip@yahoo.co.uk>
Tue, 14 Dec 2021 16:46:07 +0000 (16:46 +0000)
committerGitHub <noreply@github.com>
Tue, 14 Dec 2021 16:46:07 +0000 (16:46 +0000)
Lib/test/test_logging.py

index c85d26e4bab69d97bc6f642efb77b9bd56dccc0f..e61ccdf86bdea8c3f89098effaf15ecdee2a8292 100644 (file)
@@ -5451,7 +5451,8 @@ class TimedRotatingFileHandlerTest(BaseFileTest):
             p = os.path.join(wd, '%s.log' % prefix)
             rotator = logging.handlers.TimedRotatingFileHandler(p, when='s',
                                                                 interval=5,
-                                                                backupCount=7)
+                                                                backupCount=7,
+                                                                delay=True)
             rotators.append(rotator)
             if prefix.startswith('a.b'):
                 for t in times: