def acquire(self, blocking=True, timeout=None, num_locks=None):
    'Acquire the lock\n\n        Parameters\n        ----------\n        blocking : bool, optional\n            If false, don\'t wait on the lock in the scheduler at all.\n        timeout : string or number or timedelta, optional\n            Seconds to wait on the lock in the scheduler.  This does not\n            include local coroutine time, network transfer time, etc..\n            It is forbidden to specify a timeout when blocking is false.\n            Instead of number of seconds, it is also possible to specify\n            a timedelta in string format, e.g. "200ms".\n        num_locks : int, optional\n            Number of locks needed. If None, all locks are needed\n\n        Examples\n        --------\n        >>> lock = MultiLock([\'x\', \'y\'])  # doctest: +SKIP\n        >>> lock.acquire(timeout="1s")  # doctest: +SKIP\n\n        Returns\n        -------\n        True or False whether or not it successfully acquired the lock\n        '
    timeout = parse_timedelta(timeout)
    if (not blocking):
        if (timeout is not None):
            raise ValueError("can't specify a timeout for a non-blocking call")
        timeout = 0
    result = self.client.sync(self.client.scheduler.multi_lock_acquire, locks=self.names, id=self.id, timeout=timeout, num_locks=(num_locks or len(self.names)))
    self._locked = True
    return result
Acquire the lock

Parameters
----------
blocking : bool, optional
    If false, don't wait on the lock in the scheduler at all.
timeout : string or number or timedelta, optional
    Seconds to wait on the lock in the scheduler.  This does not
    include local coroutine time, network transfer time, etc..
    It is forbidden to specify a timeout when blocking is false.
    Instead of number of seconds, it is also possible to specify
    a timedelta in string format, e.g. "200ms".
num_locks : int, optional
    Number of locks needed. If None, all locks are needed

Examples
--------
>>> lock = MultiLock(['x', 'y'])  # doctest: +SKIP
>>> lock.acquire(timeout="1s")  # doctest: +SKIP

Returns
-------
True or False whether or not it successfully acquired the lock
def acquire(self, blocking=True, timeout=None, num_locks=None):
    'Acquire the lock\n\n        Parameters\n        ----------\n        blocking : bool, optional\n            If false, don\'t wait on the lock in the scheduler at all.\n        timeout : string or number or timedelta, optional\n            Seconds to wait on the lock in the scheduler.  This does not\n            include local coroutine time, network transfer time, etc..\n            It is forbidden to specify a timeout when blocking is false.\n            Instead of number of seconds, it is also possible to specify\n            a timedelta in string format, e.g. "200ms".\n        num_locks : int, optional\n            Number of locks needed. If None, all locks are needed\n\n        Examples\n        --------\n        >>> lock = MultiLock([\'x\', \'y\'])  # doctest: +SKIP\n        >>> lock.acquire(timeout="1s")  # doctest: +SKIP\n\n        Returns\n        -------\n        True or False whether or not it successfully acquired the lock\n        '
    timeout = parse_timedelta(timeout)
    if (not blocking):
        if (timeout is not None):
            raise ValueError("can't specify a timeout for a non-blocking call")
        timeout = 0
    result = self.client.sync(self.client.scheduler.multi_lock_acquire, locks=self.names, id=self.id, timeout=timeout, num_locks=(num_locks or len(self.names)))
    self._locked = True
    return result