API error: POST: http://127.0.0.1:7860/api/predict {'error': 'LocalProtocolError', 'detail': '', 'body': '', 'errors': "Can't send data when our state is ERROR"} #11143
Unanswered
satangel2222
asked this question in
Q&A
Replies: 1 comment 1 reply
-
same issue here on MacBook Pro M1 |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Exception in callback H11Protocol.timeout_keep_alive_handler()
提示:Python 运行时抛出了一个异常。请检查疑难解答页面。
handle: <TimerHandle when=963867.968 H11Protocol.timeout_keep_alive_handler()>
Traceback (most recent call last):
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_state.py", line 249, in _fire_event_triggered_transitions
new_state = EVENT_TRIGGERED_TRANSITIONS[role][state][event_type]
KeyError: <class 'h11._events.ConnectionClosed'>
提示:Python 运行时抛出了一个异常。请检查疑难解答页面。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\Frank\AppData\Local\Programs\Python\Python310\lib\asyncio\events.py", line 80, in _run
self._context.run(self._callback, *self._args)
File "D:\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 383, in timeout_keep_alive_handler
self.conn.send(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 468, in send
data_list = self.send_with_data_passthrough(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 493, in send_with_data_passthrough
self._process_event(self.our_role, event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 242, in _process_event
self._cstate.process_event(role, type(event), server_switch_event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_state.py", line 238, in process_event
self._fire_event_triggered_transitions(role, event_type)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_state.py", line 251, in _fire_event_triggered_transitions
raise LocalProtocolError(
h11._util.LocalProtocolError: can't handle event type ConnectionClosed when role=SERVER and state=SEND_RESPONSE
API error: POST: http://127.0.0.1:7860/api/predict {'error': 'LocalProtocolError', 'detail': '', 'body': '', 'errors': "Can't send data when our state is ERROR"}
Traceback (most recent call last):
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 162, in call
await self.app(scope, receive, _send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\base.py", line 109, in call
await response(scope, receive, send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 270, in call
async with anyio.create_task_group() as task_group:
File "D:\stable-diffusion-webui\venv\lib\site-packages\anyio_backends_asyncio.py", line 597, in aexit
raise exceptions[0]
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 273, in wrap
await func()
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\base.py", line 134, in stream_response
return await super().stream_response(send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 255, in stream_response
await send(
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 159, in _send
await send(message)
File "D:\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 512, in send
output = self.conn.send(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 468, in send
data_list = self.send_with_data_passthrough(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 483, in send_with_data_passthrough
raise LocalProtocolError("Can't send data when our state is ERROR")
h11._util.LocalProtocolError: Can't send data when our state is ERROR
ERROR: Exception in ASGI application
Traceback (most recent call last):
File "D:\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 428, in run_asgi
result = await app( # type: ignore[func-returns-value]
File "D:\stable-diffusion-webui\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 78, in call
return await self.app(scope, receive, send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\fastapi\applications.py", line 273, in call
await super().call(scope, receive, send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\applications.py", line 122, in call
await self.middleware_stack(scope, receive, send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 184, in call
raise exc
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 162, in call
await self.app(scope, receive, _send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\base.py", line 109, in call
await response(scope, receive, send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 270, in call
async with anyio.create_task_group() as task_group:
File "D:\stable-diffusion-webui\venv\lib\site-packages\anyio_backends_asyncio.py", line 597, in aexit
raise exceptions[0]
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 273, in wrap
await func()
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\base.py", line 134, in stream_response
return await super().stream_response(send)
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\responses.py", line 255, in stream_response
await send(
File "D:\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 159, in _send
await send(message)
File "D:\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 512, in send
output = self.conn.send(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 468, in send
data_list = self.send_with_data_passthrough(event)
File "D:\stable-diffusion-webui\venv\lib\site-packages\h11_connection.py", line 483, in send_with_data_passthrough
raise LocalProtocolError("Can't send data when our state is ERROR")
h11._util.LocalProtocolError: Can't send data when our state is ERROR
I need to restart the terminal again in order to work properly. I couldn't generate an image anymore even after pressing "Generate" following the occurrence of an error. Could anybody teach me how to fix this?
Beta Was this translation helpful? Give feedback.
All reactions