def METHOD_NAME(table: list):
    """
    Use flooding algorithm to replace `None` values.
    Args:
        table (list):
            the list in which there are `None` values that need to be replaced
            with copies of the closest non `None` data from the list
    """
    assert_that(any(value is not None for value in table))
    not_none_values_idx = deque(idx for idx, value in enumerate(table) if value is not None)
    while not_none_values_idx:
        current_idx = not_none_values_idx.popleft()
        current_value = table[current_idx]
        previous_idx = current_idx - 1
        next_idx = current_idx + 1
        if previous_idx >= 0 and table[previous_idx] is None:  # pragma: no cover
            table[previous_idx] = deepcopy(current_value)
            not_none_values_idx.append(previous_idx)
        if next_idx < len(table) and table[next_idx] is None:  # pragma: no cover
            table[next_idx] = deepcopy(current_value)
            not_none_values_idx.append(next_idx)
    assert_that(all(value is not None for value in table))