JurajNyiri / HomeAssistant-Tapo-Control

Control for Tapo cameras as a Home Assistant component
Apache License 2.0
1.08k stars 87 forks source link

camera prewiew somtimes shows as missing image #306

Closed ewonais closed 1 year ago

ewonais commented 1 year ago

Description

when showing camera prewiev on daschbort. i hawe streams from hass disabeld. tried whit it on but cant reproduse the error

Reproduction Steps

  1. create a camera prewie on a daschbord
  2. F5 alot and wait
  3. camera prewiew hows as missing image

Expected behavior

prewiew always shows

If applicable, add error logs.

Logger: aiohttp.server Source: custom_components/tapo_control/camera.py:163 Integration: Tapo: Cameras Control (documentation, issues) First occurred: 10:34:54 (80 occurrences) Last logged: 21:11:14

Error handling request Traceback (most recent call last): File "/usr/local/lib/python3.10/site-packages/aiohttp/web_protocol.py", line 433, in _handle_request resp = await request_handler(request) File "/usr/local/lib/python3.10/site-packages/aiohttp/web_app.py", line 504, in _handle resp = await handler(request) File "/usr/local/lib/python3.10/site-packages/aiohttp/web_middlewares.py", line 117, in impl return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 85, in security_filter_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 100, in forwarded_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 80, in ban_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 235, in auth_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 146, in handle result = await result File "/usr/src/homeassistant/homeassistant/components/camera/init.py", line 734, in get return await self.handle(request, camera) File "/usr/src/homeassistant/homeassistant/components/camera/init.py", line 774, in handle stream = await camera.handle_async_mjpeg_stream(request) File "/config/custom_components/tapo_control/camera.py", line 163, in handle_async_mjpeg_stream await stream.close() File "/usr/local/lib/python3.10/site-packages/haffmpeg/core.py", line 159, in close await self._loop.run_in_executor(None, _close) File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) File "/usr/local/lib/python3.10/site-packages/haffmpeg/core.py", line 154, in _close self._proc.stdin.write(b"q") BrokenPipeError: [Errno 32] Broken pipe

Device Firmware

Version:1.3.0 Build 220909 Rel.43466n(4555)

Using stream component

No

Does camera work via official integrations?

N/A

Camera has all attributes filled out in developer tools

Yes

HASS Environment

hassos on pi4

Search for similar issues

Yes

Additional information

No response

JurajNyiri commented 1 year ago

Not an integration issue, this is either a network issue or ha issue.