You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Token can be pasted using 'Right-Click'.
Enter your token (input will not be visible):
Add token as git credential? (Y/n) y
Traceback (most recent call last):
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 406, in hf_raise_for_status
response.raise_for_status()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\requests\models.py", line 1024, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request 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 "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\hf_api.py", line 1633, in whoami
hf_raise_for_status(r)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 460, in hf_raise_for_status
raise _format(BadRequestError, message, response) from e
huggingface_hub.errors.BadRequestError: Bad request:
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in run_code
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Scripts\huggingface-cli.exe_main.py", line 7, in
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\commands\huggingface_cli.py", line 57, in main
service.run()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\commands\user.py", line 153, in run
login(
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 130, in login
interpreter_login(new_session=new_session)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 290, in interpreter_login
_login(token=token, add_to_git_credential=add_to_git_credential)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 404, in _login
token_info = whoami(token)
^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_validators.py", line 114, in _inner_fn
return fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\hf_api.py", line 1635, in whoami
raise HTTPError(
requests.exceptions.HTTPError: Invalid user token. If you didn't pass a user token, make sure you are properly logged in by executing huggingface-cli login, and if you did pass a user token, double-check it's correct. " " "
This is the issue that I am not able to solve.
Reproduction
Traceback (most recent call last):
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 406, in hf_raise_for_status
response.raise_for_status()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\requests\models.py", line 1024, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://huggingface.co/api/whoami-v2
Hi @Titiksha28, your issue is likely related to your authentication token. could you run huggingface-cli whoami to see if you're able to retrieve your Hugging Face account name ?
You can try regenerating a new token here : https://huggingface.co/settings/tokens
Describe the bug
" " " (env) PS C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator> huggingface-cli login
Token can be pasted using 'Right-Click'.
Enter your token (input will not be visible):
Add token as git credential? (Y/n) y
Traceback (most recent call last):
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 406, in hf_raise_for_status
response.raise_for_status()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\requests\models.py", line 1024, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request 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 "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\hf_api.py", line 1633, in whoami
hf_raise_for_status(r)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 460, in hf_raise_for_status
raise _format(BadRequestError, message, response) from e
huggingface_hub.errors.BadRequestError: Bad request:
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in run_code
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Scripts\huggingface-cli.exe_main.py", line 7, in
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\commands\huggingface_cli.py", line 57, in main
service.run()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\commands\user.py", line 153, in run
login(
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 130, in login
interpreter_login(new_session=new_session)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 101, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_deprecation.py", line 31, in inner_f
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 290, in interpreter_login
_login(token=token, add_to_git_credential=add_to_git_credential)
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub_login.py", line 404, in _login
token_info = whoami(token)
^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_validators.py", line 114, in _inner_fn
return fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\hf_api.py", line 1635, in whoami
raise HTTPError(
requests.exceptions.HTTPError: Invalid user token. If you didn't pass a user token, make sure you are properly logged in by executing
huggingface-cli login
, and if you did pass a user token, double-check it's correct. " " "This is the issue that I am not able to solve.
Reproduction
Traceback (most recent call last):
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\huggingface_hub\utils_http.py", line 406, in hf_raise_for_status
response.raise_for_status()
File "C:\Users\DELL\OneDrive\Desktop\AI-Image-Generator\env\Lib\site-packages\requests\models.py", line 1024, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://huggingface.co/api/whoami-v2
Logs
No response
System info
The text was updated successfully, but these errors were encountered: