def METHOD_NAME(source: Dict[str, Any]) -> None:
    if source["type"] not in [
        "BITBUCKET",
        "CODECOMMIT",
        "CODEPIPELINE",
        "GITHUB",
        "GITHUB_ENTERPRISE",
        "NO_SOURCE",
        "S3",
    ]:
        raise InvalidInputException("Invalid type provided: Project source type")
    if "location" not in source:
        raise InvalidInputException("Project source location is required")
    if source["location"] == "":
        raise InvalidInputException("Project source location is required")