diff --git a/src/huggingface_hub/commands/user.py b/src/huggingface_hub/commands/user.py index c1498c918d..9741a219f1 100644 --- a/src/huggingface_hub/commands/user.py +++ b/src/huggingface_hub/commands/user.py @@ -36,7 +36,7 @@ import subprocess from argparse import _SubParsersAction -from typing import Optional +from typing import List, Optional from requests.exceptions import HTTPError @@ -200,7 +200,7 @@ def _select_token_name(self) -> Optional[str]: except ValueError: print("Invalid input. Please enter a number or 'q' to quit.") - def _select_token_name_tui(self, token_names: list[str]) -> Optional[str]: + def _select_token_name_tui(self, token_names: List[str]) -> Optional[str]: choices = [Choice(token_name, name=token_name) for token_name in token_names] try: return inquirer.select(