Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.72.0: Unhandled exception: ConnectionResetError: Cannot write to closing transport #15113

Closed
xcray opened this issue Jun 24, 2018 · 11 comments
Closed

Comments

@xcray
Copy link

xcray commented Jun 24, 2018

Home Assistant release with the issue:

0.72.0

Last working Home Assistant release (if known):
0.71.0

Operating environment (Hass.io/Docker/Windows/etc.):

Raspbian, virtual environment
Component/platform:

N/A

Description of problem:

After upgraded to 0.72.0, it throws the exception several times (half a day).

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):

N/A
same configuration works well on 0.71.0

Traceback (if applicable):

Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_protocol.py", line 399, in start
    await resp.write_eof()
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_response.py", line 593, in write_eof
    await super().write_eof(body)
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_response.py", line 401, in write_eof
    await self._payload_writer.write_eof(data)
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/http_writer.py", line 126, in write_eof
    self._write(chunk)
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/http_writer.py", line 57, in _write
    raise ConnectionResetError('Cannot write to closing transport')
ConnectionResetError: Cannot write to closing transport

Additional information:

@xcray
Copy link
Author

xcray commented Jun 24, 2018

After restart, the exceptions disappeared. But later it will appear again.

@xcray xcray closed this as completed Jun 24, 2018
@xcray xcray reopened this Jun 24, 2018
@VDRainer
Copy link
Contributor

+1
Error raises on closing a camera window.
There's already an open issue #14919

@jiriteach
Copy link

+1 rpi_camera no longer works throwing this error.

@xcray
Copy link
Author

xcray commented Jun 27, 2018

remains on 0.72.1

@xcray
Copy link
Author

xcray commented Jun 27, 2018

since #14919 is already there, this issue should be closed, I think.

@xcray xcray closed this as completed Jun 27, 2018
@daniarv
Copy link

daniarv commented Jul 16, 2018

Hi,

I still have this error when running Hass.io 0.73.1.
Error output:

Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/aiohttp/web_protocol.py", line 398, in start
    await resp.prepare(request)
  File "/usr/lib/python3.6/site-packages/aiohttp/web_response.py", line 300, in prepare
    return await self._start(request)
  File "/usr/lib/python3.6/site-packages/aiohttp/web_response.py", line 605, in _start
    return await super()._start(request)
  File "/usr/lib/python3.6/site-packages/aiohttp/web_response.py", line 367, in _start
    await writer.write_headers(status_line, headers)
  File "/usr/lib/python3.6/site-packages/aiohttp/http_writer.py", line 100, in write_headers
    self._write(buf)
  File "/usr/lib/python3.6/site-packages/aiohttp/http_writer.py", line 57, in _write
    raise ConnectionResetError('Cannot write to closing transport')
ConnectionResetError: Cannot write to closing transport

This in my configuration for MJPEG:

camera:
  - platform: mjpeg
    mjpeg_url: http://ipaddress/Streaming/channels/2/preview
    still_image_url: http://ipaddress/Streaming/channels/2/picture
    username: !secret hikvision_username
    password: !secret hikvision_password
    name: Huskamera
    authentication: basic  

@hwestman
Copy link

hwestman commented Jul 25, 2018

I'm struggling with this issue as well running hassio, version 0.74.0

screen shot 2018-07-25 at 08 29 21

@jezzamine
Copy link

jezzamine commented Jul 27, 2018

I have the same error message with Hass.io 0.74.2

image

@xAPPO
Copy link

xAPPO commented Aug 4, 2018

.. and I have it in 0.75

Sat Aug 04 2018 15:43:38 GMT+0100 (British Summer Time)

Unhandled exception
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/aiohttp/web_protocol.py", line 398, in start
    await resp.prepare(request)
  File "/usr/local/lib/python3.6/site-packages/aiohttp/web_response.py", line 300, in prepare
    return await self._start(request)
  File "/usr/local/lib/python3.6/site-packages/aiohttp/web_response.py", line 605, in _start
    return await super()._start(request)
  File "/usr/local/lib/python3.6/site-packages/aiohttp/web_response.py", line 367, in _start
    await writer.write_headers(status_line, headers)
  File "/usr/local/lib/python3.6/site-packages/aiohttp/http_writer.py", line 100, in write_headers
    self._write(buf)
  File "/usr/local/lib/python3.6/site-packages/aiohttp/http_writer.py", line 57, in _write
    raise ConnectionResetError('Cannot write to closing transport')
ConnectionResetError: Cannot write to closing transport

@AriZuu
Copy link

AriZuu commented Aug 4, 2018

I had this error on 0.74 with ffmpeg cameras (three different ones). Now, with 0.75 there is no longer error in log, but when I click the picture to view video, nothing is shown. Just a title with camera name but no video.

Maybe open a new issue as this one is closed already ?

@awarecan
Copy link
Contributor

This issue should be fixed in 0.75 (#15577). Anyone still experience similar problem, please open a new issue with all detail information.

I am going to lock this thread.

@home-assistant home-assistant locked as resolved and limited conversation to collaborators Aug 12, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants