I am having difficulty logging into my account using huggingface-cli login, but my token is not being recognized as a valid token. I have created several new tokens but I’m still getting a permission denied error.
The specifics:
Traceback (most recent call last):
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_http.py”, line 409, in hf_raise_for_status
response.raise_for_status()
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/requests/models.py”, line 1024, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 429 Client Error: Too Many Requests for url: https://huggingface.co/api/whoami-v2
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/hf_api.py”, line 1664, in whoami
hf_raise_for_status(r)
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_http.py”, line 481, in hf_raise_for_status
raise _format(HfHubHTTPError, str(e), response) from e
huggingface_hub.errors.HfHubHTTPError: 429 Client Error: Too Many Requests for url: https://huggingface.co/api/whoami-v2
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File “/home/mj6ux/.conda/envs/coconut/bin/huggingface-cli”, line 8, in
sys.exit(main())
^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/commands/huggingface_cli.py”, line 57, in main
service.run()
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/commands/user.py”, line 153, in run
login(
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_deprecation.py”, line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_deprecation.py”, line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/_login.py”, line 130, in login
interpreter_login(new_session=new_session)
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_deprecation.py”, line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_deprecation.py”, line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/_login.py”, line 290, in interpreter_login
_login(token=token, add_to_git_credential=add_to_git_credential)
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/_login.py”, line 404, in _login
token_info = whoami(token)
^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/utils/_validators.py”, line 114, in _inner_fn
return fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File “/home/mj6ux/.conda/envs/coconut/lib/python3.12/site-packages/huggingface_hub/hf_api.py”, line 1677, in whoami
raise HTTPError(error_message, request=e.request, response=e.response) from e
requests.exceptions.HTTPError: Invalid user token.