from typing import Optional
from typing import Dict
from typing import List


def find_skip_tags(params: Optional[Dict[str, str]] = None) -> List[str]:
    """Returns a list of tags passed in params that should be excluded from the build."""
    if params is None:
        params = {}

    tags = params.get("skip_tags", [])

    if isinstance(tags, str):
        tags = [t.strip() for t in tags.split(",") if t != ""]

    return tags