Home Assistant release with the issue:
0.104.1
Last working Home Assistant release (if known):
Operating environment (Hass.io/Docker/Windows/etc.):
Hass.io
Integration:
https://www.home-assistant.io/integrations/emulated_roku/
Description of problem:
Since Home Assistant 0.104.1 I get the following error in my log and the Roku Emulator is not working anymore. Already tried to change the port, but the problem stays the same.
Problem-relevant configuration.yaml
entries and (fill out even if it seems unimportant):
emulated_roku:
servers:
- name: Roku 4
listen_port: 6080
Traceback (if applicable):
2020-01-17 19:02:28 ERROR (MainThread) [homeassistant.components.emulated_roku] Failed to start Emulated Roku Roku 4 on 192.168.178.51:6080
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 423, in start
MULTICAST_PORT))
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
Additional information:
This is my first bug report. If you need more information, just let me know.
@Hunt4Beer which ports have you tried so far?
@springstan
I tried 6080, 6081, 8060, 8080 and 9090.
The error message is the same.
In Home Assistant version "0.103.X" everything worked fine with the default port (8060)
Isn't the default port 8060
? At least it is mentioned in the documentation example.
You are right, my fault. Seems like, that I tried much ports today...
I just edit my post.
I changed the port to 8060, but the error is still the same.
emulated_roku:
servers:
- name: Roku 4
listen_port: 8060
ERROR (MainThread) [homeassistant.components.emulated_roku] Failed to start Emulated Roku Roku 4 on 192.168.178.51:8060
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 423, in start
MULTICAST_PORT))
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
Exactly the same issue here.
Home Assistant release with the issue:
0.104.1
Last working Home Assistant release (if known):
103.6
Operating environment (Hass.io/Docker/Windows/etc.):
Docker
Integration:
https://www.home-assistant.io/integrations/emulated_roku/
Description of problem:
Since Home Assistant 0.104.1 I get the following error in my log and the Roku Emulator is not working anymore. Already tried to change the port, but the problem stays the same.
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
emulated_roku:
servers:
- name: Roku 4
listen_port: 8060
20-01-18 10:17:04 ERROR (MainThread) [homeassistant.components.emulated_roku] Failed to start Emulated Roku Home Assistant on 10.2.2.1:8060
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 423, in start
MULTICAST_PORT))
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
same here! raspberry pi 3b+, Hassio 104.1
Fri Jan 17 2020 11:13:01 GMT-0500 (EST)
Failed to start Emulated Roku Home Assistant on 192.168.1.237:8060
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 423, in start
MULTICAST_PORT))
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
I have the same problem. However, I have 2 emulated roku set up and the other one is working. Port 8060 is working
emulated_roku:
servers:
- name: Home Assistant
listen_port: 8060
advertise_port: 8060
host_ip: 192.168.1.54
- name: Home Assistant kaksi
listen_port: 8063
advertise_port: 8063
host_ip: 192.168.1.54
Running emulated_roku 0.1.8 as custom component is working ok, just get the occasional reuse_address=True error in the HA log.
@Hackashaq666 thanks for testing and confirming that 👍
Released emulated_roku 0.1.9 too early: ( Added reuse_port for 0.2.0, should work correctly now.
Hi, Sorry im experiencing this issue in Home Assistant - how do i update emulated roku in it to 0.2.0 ? sure its something easy !!
It will be part of Home Assistant 0.104.3 @rob1981forest
ah, ok - thanks a lot !
I have run 0.2.0 as custom compunent in Home Assistant 0.104.2, but I get the following error at startup, and Emulated Roku does not work. Rolling back to 0.1.8 as custom component on 0.104.2 works.
Mon Jan 20 2020 12:55:17 GMT-0500 (Eastern Standard Time)
Failed to start Emulated Roku Home Assistant on 192.168.1.237:8060
Traceback (most recent call last):
File "/config/custom_components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 424, in start
reuse_port=True)
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
Might be because emulated_roku binds 239.255.255.250, and reuse_port prevents processes with differing UIDs from binding to the same socket. It'll take a while to investigate (never occured to me to test with other users...)
edit: I think I got a fix, but it'll take a while, shouldn't need to bind that IP.
Sorry for the borked releases:(
I updated Homeassistant to version 0.104.3 inside Hass.io, but the problem stays the same :(
Also tried to use a different port, but not luck.
Is it possible to reopen the issue?
2020-01-21 17:06:10 ERROR (MainThread) [homeassistant.components.emulated_roku] Failed to start Emulated Roku Roku 4 on 192.168.178.51:8061
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 424, in start
reuse_port=True)
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
Same for me
Get Outlook for Androidhttps://aka.ms/ghei36
From: Hunt4Beer notifications@github.com
Sent: Tuesday, January 21, 2020 4:18:58 PM
To: home-assistant/home-assistant home-assistant@noreply.github.com
Cc: rob1981forest rob1981forest@hotmail.com; Mention mention@noreply.github.com
Subject: Re: [home-assistant/home-assistant] Emulated Roku "Adress in use" (#30907)
I updated Homeassistant to version 0.104.3 inside Hass.io, but the problem stays the same :(
Also tried to use a different port, but not luck.
Is it possible to reopen the issue?
2020-01-21 17:06:10 ERROR (MainThread) [homeassistant.components.emulated_roku] Failed to start Emulated Roku Roku 4 on 192.168.178.51:8061
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 424, in start
reuse_port=True)
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1252, in create_datagram_endpoint
raise exceptions[0]
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1236, in create_datagram_endpoint
sock.bind(local_address)
OSError: [Errno 98] Address in use
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/home-assistant/home-assistant/issues/30907?email_source=notifications&email_token=ALCGLUAXQUY7PWFXSLKZCLLQ64N7FA5CNFSM4KIMESHKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJQKG6I#issuecomment-576758649, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ALCGLUCV2E3WREHH27GHY5LQ64N7FANCNFSM4KIMESHA.
Should we start a new issue or re-open? This problem still exists for me too and my error log is identical to Hunt4Beer's paste above. Have updated the files to 0.2.0 and updated to 104.3 with no luck.
@jdeluyck do you experience this issue as well?
I've reproduced the error with the emulated_roku lib, working on a fix.
@jdeluyck do you experience this issue as well?
No. It just starts, on both my pi and my laptop.
Okay thanks for your input :)
I've released 0.2.1.dev1 on pypi, could anyone test it if it works? I've pretty much reverted the changes, so it should work the same as before, except without the original reuse_address error.
Thanks!
@mindigmarton
I'm not sure if I manage it to test it today. If I didn't testit today, I will try to do it tomorrow.
Can you tell me how I can test it on Hass.io?
I could test today but no idea how to get it into my docker home assistant 104.3.
Any ideas ?
Get Outlook for Androidhttps://aka.ms/ghei36
From: Hunt4Beer notifications@github.com
Sent: Wednesday, January 22, 2020 3:25:47 PM
To: home-assistant/home-assistant home-assistant@noreply.github.com
Cc: rob1981forest rob1981forest@hotmail.com; Mention mention@noreply.github.com
Subject: Re: [home-assistant/home-assistant] Emulated Roku "Adress in use" (#30907)
@mindigmartonhttps://github.com/mindigmarton
I'm not sure if I manage it to test it today. If I didn't testit today, I will try to do it tomorrow.
Can you tell me how I can test it on Hass.io?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/home-assistant/home-assistant/issues/30907?email_source=notifications&email_token=ALCGLUA74DEZAZQGBIPKNQDQ7BQPXA5CNFSM4KIMESHKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJT7RVI#issuecomment-577239253, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ALCGLUEPAZZHDYSGCTW2GFDQ7BQPXANCNFSM4KIMESHA.
I could test today but no idea how to get it into my docker home assistant 104.3. Any ideas ?
Similarly, I know how to use custom component on Hassio, but not sure how to get the files from 0.2.1.dev1 on pypi, the folder/file structure is not the same as home-assistant component as far as I ca see.
Just drop the emulated_roku component from home assistant into custom_components, then change the version in manifest.json. You don’t have to download anything manually from pypi.
When you open a PR for this upgrade, please mention that it's for a hot fix
I've released 0.2.1.dev1 on pypi, could anyone test it if it works? I've pretty much reverted the changes, so it should work the same as before, except without the original reuse_address error.
Thanks!
This works for me. The error is gone, I get a response if I open http://192.168.XXX.XXX:8060/ and I receive roku_command events.
Well done! Thank you.
I've released 0.2.1.dev1 on pypi, could anyone test it if it works? I've pretty much reverted the changes, so it should work the same as before, except without the original reuse_address error.
Thanks!This works for me. The error is gone, I get a response if I open http://192.168.XXX.XXX:8060/ and I receive roku_command events.
Well done! Thank you.
I agree with sti0, all is working and errors are gone from log. Thanks @mindigmarton!
Does anybody know, when home assistant version 0.104.4 (including this bugfix) will be released ?
They run on a 3 week release cycle from the .0 so we should see this released in about a week from now.
Confirming this issue still exists in 0.105.5.
Failed to start Emulated Roku Home Assistant Roku on 192.168.7.222:8060
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/emulated_roku/binding.py", line 142, in emulated_roku_start
await self._api_server.start()
File "/usr/local/lib/python3.7/site-packages/emulated_roku/__init__.py", line 408, in start
await api_endpoint.start()
File "/usr/local/lib/python3.7/site-packages/aiohttp/web_runner.py", line 104, in start
reuse_port=self._reuse_port)
File "/usr/local/lib/python3.7/asyncio/base_events.py", line 1385, in create_server
% (sa, err.strerror.lower())) from None
OSError: [Errno 98] error while attempting to bind on address ('192.168.7.222', 8060): address in use
That’s a different issue, the http (tcp) port is in use. Find another free port for emulated_roku.
Most helpful comment
I've reproduced the error with the emulated_roku lib, working on a fix.