bpo-46063: Add 'delay=True' to file handler initialization. (GH-30103)

This commit is contained in:
Vinay Sajip 2021-12-14 16:46:07 +00:00 committed by GitHub
parent 1cbb88736c
commit 850aefc2c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

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