Error while running the interface.
#395
by
MShijas
- opened
I am using the Hugging Face model Qwen/Qwen2.5-Coder-32B-Instruct with a Gradio interface. When trying to generate a response, I get the following error:
401 Client Error: Unauthorized for url: https://router.huggingface.co/hf-inference/models/Qwen/Qwen2.5-Coder-32B-Instruct/v1/chat/completions
Invalid username or password.
After this, the application throws a Python exception:
TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'
File ".../Gradio_UI.py", line 145, in stream_to_gradio
total_input_tokens += agent.model.last_input_token_count
How can I properly handle this error and fix the token authentication issue?
same error in my case
solved with "Create a secret with the name HF_TOKEN"