def METHOD_NAME(item: T) -> str:
    if isinstance(item, str):
        return item
    if isinstance(item, Path):
        return str(item)
    raise ValueError(f"Please provide `key` argument in `filter_repo_objects`: `{item}` is not a string.")