def __init__(self, name, scheduler=None):
        """
        @param name: The name of the lock to acquire
        @param scheduler: An object which provides L{IReactorTime}
        """
        lockfile.FilesystemLock.__init__(self, name)

        if scheduler is None:
            from twisted.internet import reactor
            scheduler = reactor

        self._scheduler = scheduler

        @param name: The name of the lock to acquire
        @param scheduler: An object which provides L{IReactorTime}
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/internet/defer.py