def METHOD_NAME(self, timeout):
    """
    Scoped timeout setter.  Sets the timeout within the scope,
    and restores it when leaving the scope.
    """
    if timeout is self.default or timeout == self.timeout:
        return _DummyContext
    return _local_handler(self, timeout)