def validate_path_element(elem):
    """Check if a single path element is valid.

    :param elem: (str) A part of an dotted path (no dots allowed)
    :raises: ValueError if invalid.
    """
    if len(elem) is 0:
        raise ValueError('Path elements may not be empty')
    if '.' in elem:
        raise ValueError('Path elements should contain no dot')
