from typing import Any
from typing import Iterable


def _listify(x: Any):
    """Convert value to list if it is not already iterable."""
    if not isinstance(x, Iterable):
        return [x]
    else:
        return x