'Open the specified file and use it as the stream for logging.'

def __init__(self, filename, mode='a', encoding=None, delay=0):

    if (codecs is None):
        encoding = None
    self.baseFilename = os.path.abspath(filename)
    self.mode = mode
    self.encoding = encoding
    if delay:
        Handler.__init__(self)
        self.stream = None
    else:
        StreamHandler.__init__(self, self._open())
