The log directory may not yet exist.

This commit is contained in:
Jean-Paul Calderone 2019-03-04 10:08:53 -05:00
parent c6a2aa9fc7
commit 26a7cc4f21

View File

@ -458,12 +458,14 @@ class _DestinationParser(object):
10,
arg_list,
))
get_file = lambda: LogFile(
path.basename(),
path.dirname(),
rotateLength=rotate_length,
maxRotatedFiles=max_rotated_files,
)
def get_file():
path.parent().makedirs(ignoreExistingDirectory=True)
return LogFile(
path.basename(),
path.dirname(),
rotateLength=rotate_length,
maxRotatedFiles=max_rotated_files,
)
return lambda reactor: FileDestination(get_file())