from typing import List


def parse_list_of_int(s: str) -> List[int]:
    """Parses a list of int's from a string, and returns it.

    Examples:

        >>> parse_list_of_int('')
        []
        >>> parse_list_of_int('1')
        [1]
        >>> parse_list_of_int('1,20')
        [1, 20]
        >>> parse_list_of_int('1, 20 , 30  ,  40')
        [1, 20, 30, 40]
        >>> parse_list_of_int('1,')
        Traceback (most recent call last):
        ...
        ValueError: invalid literal for int() with base 10: ''
    """
    return [] if not s else [int(s.strip()) for s in s.split(",")]